diff options
author | jack wang <jack_wang@usish.com> | 2009-12-07 04:22:47 -0500 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2009-12-10 11:02:22 -0500 |
commit | afc5ca9ddc6c223dbea8a2f8816a88b21a0883b5 (patch) | |
tree | 776fa8c54e07ed3ad5b5c23b92f14db4e3822101 /drivers/scsi/pm8001/pm8001_hwi.c | |
parent | 1cc943ae5003e4612a73119cb6fb637a45c2714d (diff) |
[SCSI] pm8001: fix endian issues with SAS address
Signed-off-by: Jack Wang <jack_wang@usish.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/pm8001/pm8001_hwi.c')
-rw-r--r-- | drivers/scsi/pm8001/pm8001_hwi.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/scsi/pm8001/pm8001_hwi.c b/drivers/scsi/pm8001/pm8001_hwi.c index 3a121fbd4fc5..b4426b5b50bc 100644 --- a/drivers/scsi/pm8001/pm8001_hwi.c +++ b/drivers/scsi/pm8001/pm8001_hwi.c | |||
@@ -3823,7 +3823,8 @@ static int pm8001_chip_ssp_io_req(struct pm8001_hba_info *pm8001_ha, | |||
3823 | u32 opc = OPC_INB_SSPINIIOSTART; | 3823 | u32 opc = OPC_INB_SSPINIIOSTART; |
3824 | memset(&ssp_cmd, 0, sizeof(ssp_cmd)); | 3824 | memset(&ssp_cmd, 0, sizeof(ssp_cmd)); |
3825 | memcpy(ssp_cmd.ssp_iu.lun, task->ssp_task.LUN, 8); | 3825 | memcpy(ssp_cmd.ssp_iu.lun, task->ssp_task.LUN, 8); |
3826 | ssp_cmd.dir_m_tlr = data_dir_flags[task->data_dir] << 8 | 0x0;/*0 for | 3826 | ssp_cmd.dir_m_tlr = |
3827 | cpu_to_le32(data_dir_flags[task->data_dir] << 8 | 0x0);/*0 for | ||
3827 | SAS 1.1 compatible TLR*/ | 3828 | SAS 1.1 compatible TLR*/ |
3828 | ssp_cmd.data_len = cpu_to_le32(task->total_xfer_len); | 3829 | ssp_cmd.data_len = cpu_to_le32(task->total_xfer_len); |
3829 | ssp_cmd.device_id = cpu_to_le32(pm8001_dev->device_id); | 3830 | ssp_cmd.device_id = cpu_to_le32(pm8001_dev->device_id); |
@@ -3894,7 +3895,7 @@ static int pm8001_chip_sata_req(struct pm8001_hba_info *pm8001_ha, | |||
3894 | } | 3895 | } |
3895 | } | 3896 | } |
3896 | if (task->ata_task.use_ncq && pm8001_get_ncq_tag(task, &hdr_tag)) | 3897 | if (task->ata_task.use_ncq && pm8001_get_ncq_tag(task, &hdr_tag)) |
3897 | ncg_tag = cpu_to_le32(hdr_tag); | 3898 | ncg_tag = hdr_tag; |
3898 | dir = data_dir_flags[task->data_dir] << 8; | 3899 | dir = data_dir_flags[task->data_dir] << 8; |
3899 | sata_cmd.tag = cpu_to_le32(tag); | 3900 | sata_cmd.tag = cpu_to_le32(tag); |
3900 | sata_cmd.device_id = cpu_to_le32(pm8001_ha_dev->device_id); | 3901 | sata_cmd.device_id = cpu_to_le32(pm8001_ha_dev->device_id); |
@@ -4039,7 +4040,7 @@ static int pm8001_chip_reg_dev_req(struct pm8001_hba_info *pm8001_ha, | |||
4039 | ((stp_sspsmp_sata & 0x03) * 0x10000000)); | 4040 | ((stp_sspsmp_sata & 0x03) * 0x10000000)); |
4040 | payload.firstburstsize_ITNexustimeout = | 4041 | payload.firstburstsize_ITNexustimeout = |
4041 | cpu_to_le32(ITNT | (firstBurstSize * 0x10000)); | 4042 | cpu_to_le32(ITNT | (firstBurstSize * 0x10000)); |
4042 | memcpy(&payload.sas_addr_hi, pm8001_dev->sas_device->sas_addr, | 4043 | memcpy(payload.sas_addr, pm8001_dev->sas_device->sas_addr, |
4043 | SAS_ADDR_SIZE); | 4044 | SAS_ADDR_SIZE); |
4044 | rc = mpi_build_cmd(pm8001_ha, circularQ, opc, &payload); | 4045 | rc = mpi_build_cmd(pm8001_ha, circularQ, opc, &payload); |
4045 | return rc; | 4046 | return rc; |