[SCSI] sg: protect sdp->exclude
authorJörn Engel <joern@logfs.org>
Tue, 24 Apr 2012 20:13:11 +0000 (16:13 -0400)
committerJames Bottomley <JBottomley@Parallels.com>
Thu, 17 May 2012 09:08:55 +0000 (10:08 +0100)
Changes since v1: set_exclude now returns the new value, which gets
rid of the comma expression and the operator precedence bug.  Thanks
to Douglas for spotting it.

sdp->exclude was previously protected by the BKL.  The sg_mutex, which
replaced the BKL, only semi-protected it, as it was missing from
sg_release() and sg_proc_seq_show_debug().  Take an explicit spinlock
for it.

Signed-off-by: Joern Engel <joern@logfs.org>
Acked-by: Douglas Gilbert <dgilbert@interlog.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>

No differences found