[SCSI] libsas: fix deref before check in commit 70b25f890ce
authorJames Bottomley <James.Bottomley@suse.de>
Thu, 13 May 2010 14:31:54 +0000 (09:31 -0500)
committerJames Bottomley <James.Bottomley@suse.de>
Sun, 16 May 2010 19:34:58 +0000 (15:34 -0400)
commit1b4d0d8ea7b3cbd107f345ab766416f9b38ce66a
treea5aeda206eb92e702ad7e9b9e2b91e50fa6964d2
parentb5dbc858717113c823fe6bb058807c2cb67d1efa
[SCSI] libsas: fix deref before check in commit 70b25f890ce

commit 70b25f890ce9f0520c64075ce9225a5b020a513e
Author: Tejun Heo <tj@kernel.org>
Date:   Thu Apr 15 09:00:08 2010 +0900

    [SCSI] fix locking around blk_abort_request()

Introduced a reference before check problem, fix this by moving the
lock shorthand code to be right at the point of actual use.

Reported-by: Dan Carpenter <error27@gmail.com>
Acked-by: Tejun Heo <tj@kernel.org>
Cc: Stable Tree <stable@kernel.org>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
drivers/scsi/libsas/sas_ata.c
drivers/scsi/libsas/sas_scsi_host.c