aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/qla2xxx
diff options
context:
space:
mode:
authorJoe Carnuccio <joe.carnuccio@qlogic.com>2011-05-10 14:30:11 -0400
committerJames Bottomley <jbottomley@parallels.com>2011-05-17 03:34:20 -0400
commit1bff6cc8fbb73d6bed809d3eff18e90c175a601c (patch)
treec434f4ddfdaf4b96800ca394f0b47102a97625ee /drivers/scsi/qla2xxx
parentd652e0937029e1f7cf9b17d639782db1b0c23ea9 (diff)
[SCSI] qla2xxx: Correctly read sfp single byte mailbox register.
When reading a single byte using the READ SFP mailbox command, the single byte of data is returned in MB[1] and not MB[8]. The reason that MB[8] was being used is that the spec was unclear as it evolved over time; and we have not needed to read a single byte until recently. Signed-off-by: Joe Carnuccio <joe.carnuccio@qlogic.com> Signed-off-by: Madhuranath Iyengar <Madhu.Iyengar@qlogic.com> Signed-off-by: James Bottomley <jbottomley@parallels.com> Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/qla2xxx')
-rw-r--r--drivers/scsi/qla2xxx/qla_mbx.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/scsi/qla2xxx/qla_mbx.c b/drivers/scsi/qla2xxx/qla_mbx.c
index 975aeaae297a..aab628bf8d36 100644
--- a/drivers/scsi/qla2xxx/qla_mbx.c
+++ b/drivers/scsi/qla2xxx/qla_mbx.c
@@ -3608,14 +3608,14 @@ qla2x00_read_edc(scsi_qla_host_t *vha, uint16_t dev, uint16_t adr,
3608 mcp->mb[9] = adr; 3608 mcp->mb[9] = adr;
3609 mcp->mb[10] = opt; 3609 mcp->mb[10] = opt;
3610 mcp->out_mb = MBX_10|MBX_9|MBX_8|MBX_7|MBX_6|MBX_3|MBX_2|MBX_1|MBX_0; 3610 mcp->out_mb = MBX_10|MBX_9|MBX_8|MBX_7|MBX_6|MBX_3|MBX_2|MBX_1|MBX_0;
3611 mcp->in_mb = MBX_0; 3611 mcp->in_mb = MBX_1|MBX_0;
3612 mcp->tov = MBX_TOV_SECONDS; 3612 mcp->tov = MBX_TOV_SECONDS;
3613 mcp->flags = 0; 3613 mcp->flags = 0;
3614 rval = qla2x00_mailbox_command(vha, mcp); 3614 rval = qla2x00_mailbox_command(vha, mcp);
3615 3615
3616 if (opt & BIT_0) 3616 if (opt & BIT_0)
3617 if (sfp) 3617 if (sfp)
3618 *sfp = mcp->mb[8]; 3618 *sfp = mcp->mb[1];
3619 3619
3620 if (rval != QLA_SUCCESS) { 3620 if (rval != QLA_SUCCESS) {
3621 DEBUG2_3_11(printk("%s(%ld): failed=%x (%x).\n", __func__, 3621 DEBUG2_3_11(printk("%s(%ld): failed=%x (%x).\n", __func__,