]> asedeno.scripts.mit.edu Git - linux.git/commit
scsi: mac_esp: Replace bogus memory barrier with spinlock
authorFinn Thain <fthain@telegraphics.com.au>
Sun, 2 Apr 2017 07:08:05 +0000 (17:08 +1000)
committerMartin K. Petersen <martin.petersen@oracle.com>
Tue, 25 Apr 2017 17:00:59 +0000 (13:00 -0400)
commit4da2b1eb230ba4ad19b58984dc52e05b1073df5f
treec6bcd3f383f9e766bd2fd65b741d424e27433553
parent62d57f20ff6d9715c5d7605c5b6b1a2e6f4fbbd8
scsi: mac_esp: Replace bogus memory barrier with spinlock

Commit da244654c66e ("[SCSI] mac_esp: fix for quadras with two esp
chips") added mac_scsi_esp_intr() to handle the IRQ lines from a pair of
on-board ESP chips (a normal shared IRQ did not work).

Proper mutual exclusion was missing from that patch. This patch fixes
race conditions between comparison and assignment of esp_chips[]
pointers.

Signed-off-by: Finn Thain <fthain@telegraphics.com.au>
Reviewed-by: Michael Schmitz <schmitzmic@gmail.com>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/mac_esp.c