summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aacraid
diff options
context:
space:
mode:
authorMark Haverkamp <markh@osdl.org>2005-11-30 12:01:39 -0800
committerJames Bottomley <jejb@mulgrave.(none)>2005-12-01 15:59:44 -0600
commit8bdf810f89c3e686ba18a11e2852f32014f1506a (patch)
tree899aaf094c61b20a7ef5d3d7bc1ee3c5c2c57533 /drivers/scsi/aacraid
parent349cd7cfe6ba0b2e7cd2afdc3e70ede845311afe (diff)
downloadblackbird-op-linux-8bdf810f89c3e686ba18a11e2852f32014f1506a.tar.gz
blackbird-op-linux-8bdf810f89c3e686ba18a11e2852f32014f1506a.zip
[SCSI] aacraid: Check scsi_bios_ptabe return code
Received from Mark Salyzyn. scsi_bios_ptable return value is not being checked in aac_biosparm. Signed-off-by: Mark Haverkamp <markh@osdl.org> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/aacraid')
-rw-r--r--drivers/scsi/aacraid/linit.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/scsi/aacraid/linit.c b/drivers/scsi/aacraid/linit.c
index ab383d1f59e2..3cb68af90456 100644
--- a/drivers/scsi/aacraid/linit.c
+++ b/drivers/scsi/aacraid/linit.c
@@ -325,6 +325,8 @@ static int aac_biosparm(struct scsi_device *sdev, struct block_device *bdev,
* translations ( 64/32, 128/32, 255/63 ).
*/
buf = scsi_bios_ptable(bdev);
+ if (!buf)
+ return 0;
if(*(__le16 *)(buf + 0x40) == cpu_to_le16(0xaa55)) {
struct partition *first = (struct partition * )buf;
struct partition *entry = first;
OpenPOWER on IntegriCloud