diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/hpsa.c | 25 |
1 files changed, 5 insertions, 20 deletions
diff --git a/drivers/scsi/hpsa.c b/drivers/scsi/hpsa.c index 4e7df2e5701e..264c1764befe 100644 --- a/drivers/scsi/hpsa.c +++ b/drivers/scsi/hpsa.c | |||
@@ -1647,30 +1647,15 @@ static void figure_bus_target_lun(struct ctlr_info *h, | |||
1647 | *target = (lunid >> 16) & 0x3fff; | 1647 | *target = (lunid >> 16) & 0x3fff; |
1648 | *lun = lunid & 0x00ff; | 1648 | *lun = lunid & 0x00ff; |
1649 | } else { | 1649 | } else { |
1650 | if (likely(is_scsi_rev_5(h))) { | 1650 | *bus = 0; |
1651 | /* All current smart arrays (circa 2011) */ | 1651 | *target = 0; |
1652 | *bus = 0; | 1652 | *lun = (lunid & 0x3fff); |
1653 | *target = 0; | ||
1654 | *lun = (lunid & 0x3fff) + 1; | ||
1655 | } else { | ||
1656 | /* Traditional old smart array way. */ | ||
1657 | *bus = 0; | ||
1658 | *target = lunid & 0x3fff; | ||
1659 | *lun = 0; | ||
1660 | } | ||
1661 | } | 1653 | } |
1662 | } else { | 1654 | } else { |
1663 | /* physical device */ | ||
1664 | if (is_hba_lunid(lunaddrbytes)) | 1655 | if (is_hba_lunid(lunaddrbytes)) |
1665 | if (unlikely(is_scsi_rev_5(h))) { | 1656 | *bus = 3; /* controller */ |
1666 | *bus = 0; /* put p1210m ctlr at 0,0,0 */ | ||
1667 | *target = 0; | ||
1668 | *lun = 0; | ||
1669 | return; | ||
1670 | } else | ||
1671 | *bus = 3; /* traditional smartarray */ | ||
1672 | else | 1657 | else |
1673 | *bus = 2; /* physical disk */ | 1658 | *bus = 2; /* physical device */ |
1674 | *target = -1; | 1659 | *target = -1; |
1675 | *lun = -1; /* we will fill these in later. */ | 1660 | *lun = -1; /* we will fill these in later. */ |
1676 | } | 1661 | } |