fix reentrancy bug in arcmsr_get_iop_{r,w}qbuffer()
authorAl Viro <viro@ftp.linux.org.uk>
Mon, 29 Oct 2007 05:08:58 +0000 (05:08 +0000)
committerLinus Torvalds <torvalds@woody.linux-foundation.org>
Mon, 29 Oct 2007 14:41:33 +0000 (07:41 -0700)
doh...

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
drivers/scsi/arcmsr/arcmsr_hba.c

index 4c1b3b4ae35be2a17a4dc8c2f3861964beeaf935..2f34cdb0bec197333912ea72a98cb51770de4830 100644 (file)
@@ -1068,7 +1068,7 @@ static void arcmsr_iop_message_wrote(struct AdapterControlBlock *acb)
 
 struct QBUFFER __iomem *arcmsr_get_iop_rqbuffer(struct AdapterControlBlock *acb)
 {
-       static struct QBUFFER __iomem *qbuffer;
+       struct QBUFFER __iomem *qbuffer = NULL;
 
        switch (acb->adapter_type) {
 
@@ -1089,7 +1089,7 @@ struct QBUFFER __iomem *arcmsr_get_iop_rqbuffer(struct AdapterControlBlock *acb)
 
 static struct QBUFFER __iomem *arcmsr_get_iop_wqbuffer(struct AdapterControlBlock *acb)
 {
-       static struct QBUFFER __iomem *pqbuffer;
+       struct QBUFFER __iomem *pqbuffer = NULL;
 
        switch (acb->adapter_type) {