Commit 5a5c27b611a7e97c05e4317c5b90e68c2ff44ec8

Authored by Joe Carnuccio
Committed by James Bottomley
1 parent 454073c905

[SCSI] qla2xxx: Select link initialization option bits from current operating mode.

Signed-off-by: Joe Carnuccio <joe.carnuccio@qlogic.com>
Signed-off-by: Saurav Kashyap <saurav.kashyap@qlogic.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>

Showing 1 changed file with 5 additions and 1 deletions Side-by-side Diff

drivers/scsi/qla2xxx/qla_mbx.c
... ... @@ -1667,7 +1667,11 @@
1667 1667 return QLA_FUNCTION_FAILED;
1668 1668  
1669 1669 mcp->mb[0] = MBC_LINK_INITIALIZATION;
1670   - mcp->mb[1] = BIT_6|BIT_4;
  1670 + mcp->mb[1] = BIT_4;
  1671 + if (vha->hw->operating_mode == LOOP)
  1672 + mcp->mb[1] |= BIT_6;
  1673 + else
  1674 + mcp->mb[1] |= BIT_5;
1671 1675 mcp->mb[2] = 0;
1672 1676 mcp->mb[3] = 0;
1673 1677 mcp->out_mb = MBX_3|MBX_2|MBX_1|MBX_0;