Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 88197966 authored by Anil Ravindranath's avatar Anil Ravindranath Committed by James Bottomley
Browse files

[SCSI] pmcraid: Fix ppc64 driver build for using cpu_to_le32 on U8 data type



Fix a reported ppc64 driver build issue. Removed cpu_to_le32 conversion
usage for flags in struct pmcraid_ioadl_desc. This was breaking the driver build in ppc64.

drivers/scsi/pmcraid.c: In function 'pmcraid_request_sense':
drivers/scsi/pmcraid.c:2254: warning: large integer implicitly truncated
to unsigned type

Signed-off-by: default avatarAnil <Ravindranath&lt;anil_ravindranath@pmc-sierra.com>
Signed-off-by: default avatarJames Bottomley <James.Bottomley@suse.de>
parent 3feeb89d
Loading
Loading
Loading
Loading
+5 −5
Original line number Original line Diff line number Diff line
@@ -1071,7 +1071,7 @@ static struct pmcraid_cmd *pmcraid_init_hcam


	ioarcb->data_transfer_length = cpu_to_le32(rcb_size);
	ioarcb->data_transfer_length = cpu_to_le32(rcb_size);


	ioadl[0].flags |= cpu_to_le32(IOADL_FLAGS_READ_LAST);
	ioadl[0].flags |= IOADL_FLAGS_READ_LAST;
	ioadl[0].data_len = cpu_to_le32(rcb_size);
	ioadl[0].data_len = cpu_to_le32(rcb_size);
	ioadl[0].address = cpu_to_le32(dma);
	ioadl[0].address = cpu_to_le32(dma);


@@ -2251,7 +2251,7 @@ static void pmcraid_request_sense(struct pmcraid_cmd *cmd)


	ioadl->address = cpu_to_le64(cmd->sense_buffer_dma);
	ioadl->address = cpu_to_le64(cmd->sense_buffer_dma);
	ioadl->data_len = cpu_to_le32(SCSI_SENSE_BUFFERSIZE);
	ioadl->data_len = cpu_to_le32(SCSI_SENSE_BUFFERSIZE);
	ioadl->flags = cpu_to_le32(IOADL_FLAGS_LAST_DESC);
	ioadl->flags = IOADL_FLAGS_LAST_DESC;


	/* request sense might be called as part of error response processing
	/* request sense might be called as part of error response processing
	 * which runs in tasklets context. It is possible that mid-layer might
	 * which runs in tasklets context. It is possible that mid-layer might
@@ -3017,7 +3017,7 @@ static int pmcraid_build_ioadl(
		ioadl[i].flags = 0;
		ioadl[i].flags = 0;
	}
	}
	/* setup last descriptor */
	/* setup last descriptor */
	ioadl[i - 1].flags = cpu_to_le32(IOADL_FLAGS_LAST_DESC);
	ioadl[i - 1].flags = IOADL_FLAGS_LAST_DESC;


	return 0;
	return 0;
}
}
@@ -3387,7 +3387,7 @@ static int pmcraid_build_passthrough_ioadls(
	}
	}


	/* setup the last descriptor */
	/* setup the last descriptor */
	ioadl[i - 1].flags = cpu_to_le32(IOADL_FLAGS_LAST_DESC);
	ioadl[i - 1].flags = IOADL_FLAGS_LAST_DESC;


	return 0;
	return 0;
}
}
@@ -5314,7 +5314,7 @@ static void pmcraid_querycfg(struct pmcraid_cmd *cmd)
		cpu_to_le32(sizeof(struct pmcraid_config_table));
		cpu_to_le32(sizeof(struct pmcraid_config_table));


	ioadl = &(ioarcb->add_data.u.ioadl[0]);
	ioadl = &(ioarcb->add_data.u.ioadl[0]);
	ioadl->flags = cpu_to_le32(IOADL_FLAGS_LAST_DESC);
	ioadl->flags = IOADL_FLAGS_LAST_DESC;
	ioadl->address = cpu_to_le64(pinstance->cfg_table_bus_addr);
	ioadl->address = cpu_to_le64(pinstance->cfg_table_bus_addr);
	ioadl->data_len = cpu_to_le32(sizeof(struct pmcraid_config_table));
	ioadl->data_len = cpu_to_le32(sizeof(struct pmcraid_config_table));