firewire: fw-sbp2: better fix for NULL pointer dereference in scsi_remove_device
authorStefan Richter <stefanr@s5r6.in-berlin.de>
Tue, 26 Feb 2008 22:30:02 +0000 (23:30 +0100)
committerStefan Richter <stefanr@s5r6.in-berlin.de>
Sun, 2 Mar 2008 11:35:46 +0000 (12:35 +0100)
Patch "firewire: fw-sbp2: fix NULL pointer deref. in scsi_remove_device"
had the unintended effect that firewire-sbp2 could not be unloaded
anymore until all SBP-2 devices were unplugged.

We now fix the NULL pointer bug by reacquiring a reference to the sdev
instead of holding a reference to the sdev (and to the module) all the
time.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
Tested-by: Jarod Wilson <jwilson@redhat.com>

No differences found