OSDN Git Service

[PATCH] sym53c8xx_2 SMP deadlock on driver load
authorTony Battersby <tonyb@cybernetics.com>
Wed, 17 Oct 2007 16:22:11 +0000 (12:22 -0400)
committerWilly Tarreau <w@1wt.eu>
Sun, 11 Nov 2007 17:44:01 +0000 (18:44 +0100)
commitee731f57c03a321e73eb700a06e9c0172d505ffa
tree961f4c82b1276abc10e8c5489c35123acb01a12f
parent6108030961d673432cd3cad0f317379b4b526129
[PATCH] sym53c8xx_2 SMP deadlock on driver load

This patch fixes two problems with sym53c8xx_2.o in 2.4.x kernels:

1) A system hang when loading sym53c8xx_2.o on a SMP system with two
dual-channel LSI HBAs (http://bugzilla.kernel.org/show_bug.cgi?id=3680)

2) A function improperly marked __init.

Comment from Matthew Wilcox:
" This is a pretty ugly patch, but I think the three alternatives are
  worse:

   - Drop the iorl at the beginning of ->detect and reacquire it at exit.
     We don't know what else the iorl might be protecting.  Probably
     nothing, but I don't want to audit it.
   - Convert sym2 back to old error handling so the midlayer doesn't
     acquire the iorl for us in ->detect.
   - Acquire the iorl in ->release.  We might deadlock on something.

   So, sure, apply this patch. "

Signed-off-by: Tony Battersby <tonyb@cybernetics.com>
drivers/scsi/sym53c8xx_2/sym_glue.c