diff options
author | Mark Haverkamp | 2005-09-01 17:19:23 +0200 |
---|---|---|
committer | James Bottomley | 2005-09-05 02:46:06 +0200 |
commit | 77d71d222e871670300f3e3092e2a06f20c842f0 (patch) | |
tree | 0cec7672a87b0becb254e67482c69074594943cb /drivers/scsi/aacraid | |
parent | [SCSI] sg direct io/mmap oops, st sync (diff) | |
download | kernel-qcow2-linux-77d71d222e871670300f3e3092e2a06f20c842f0.tar.gz kernel-qcow2-linux-77d71d222e871670300f3e3092e2a06f20c842f0.tar.xz kernel-qcow2-linux-77d71d222e871670300f3e3092e2a06f20c842f0.zip |
[SCSI] aacraid: bad BUG_ON fix
This was noticed by Doug Bazamic and the fix found by Mark Salyzyn at
Adaptec.
There was an error in the BUG_ON() statement that validated the
calculated fib size which can cause the driver to panic.
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/aachba.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/scsi/aacraid/aachba.c b/drivers/scsi/aacraid/aachba.c index 83bfab73ff65..a8e3dfcd0dc7 100644 --- a/drivers/scsi/aacraid/aachba.c +++ b/drivers/scsi/aacraid/aachba.c @@ -972,7 +972,7 @@ static int aac_read(struct scsi_cmnd * scsicmd, int cid) fibsize = sizeof(struct aac_read64) + ((le32_to_cpu(readcmd->sg.count) - 1) * sizeof (struct sgentry64)); - BUG_ON (fibsize > (sizeof(struct hw_fib) - + BUG_ON (fibsize > (dev->max_fib_size - sizeof(struct aac_fibhdr))); /* * Now send the Fib to the adapter |