[SCSI] advansys: fix narrow board error path
commit9a908c1aa4d3898f62e2cb8af6936b16503ab3e6
authorHerton Ronaldo Krzesinski <herton@mandriva.com.br>
Tue, 30 Mar 2010 16:35:38 +0000 (30 13:35 -0300)
committerJames Bottomley <James.Bottomley@suse.de>
Sat, 1 May 2010 14:54:22 +0000 (1 09:54 -0500)
treef22d4a95f76bb3a9bc33198dea23033ec2e044ac
parentbe1066bbcd443a65df312fdecea7e4959adedb45
[SCSI] advansys: fix narrow board error path

Error handling on advansys_board_found is fixed, because it's buggy in
the case we have an ASC_NARROW_BOARD set and failure happens on
AscInitAsc1000Driver step: it was freeing items of wrong struct in the
dvc_var union of struct asc_board, which could lead to an oops in the
case we set some of the fields in struct of narrow board as code was
choosing to always freeing wide board fields, and not everything was
being freed/released properly.

Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/advansys.c