]> git.baikalelectronics.ru Git - kernel.git/commit
[SCSI] mpt2sas: Sanity check for phy count is added using max phy count
authorKashyap, Desai <kashyap.desai@lsi.com>
Fri, 12 Nov 2010 23:10:51 +0000 (04:40 +0530)
committerJames Bottomley <James.Bottomley@suse.de>
Tue, 21 Dec 2010 18:24:08 +0000 (12:24 -0600)
commit375bbb533c75b38b39239393f2bea8097f05dbc7
treec92b67bd0f4aad01351bc383b32e01ef23a8e420
parent58c4f6d18210d5ceb9b453a090cb1faf380e84c0
[SCSI] mpt2sas: Sanity check for phy count is added using max phy count

Fix oops loading driver when there is direct attached
SEP device

The driver set max phys count to the value reported in sas iounit page
zero.  However this page doesn't take into account additional virutal
phys.  When sas topology event arrives, the phy count is larger than
expected, and the driver accesses memory array beyond the end of
allocated space, then oops.  Manufacturing page 8 contains the info
on direct attached phys.

For this fix will making sure that sas topology event is not
processing phys greater than the expected phy count.

Signed-off-by: Kashyap Desai <kashyap.desai@lsi.com>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/mpt2sas/mpt2sas_scsih.c