It appears that certain configurations which use the md driver may be the ones that are having the hanging problem when shutting down. It looks like some bit of code is trying to send a command after the control thread has been terminated.
The attached patch makes the control thread unkillable. It's probably a
good idea anyway, but I'd like people who are experiencing the
"hang/long-delay on shutdown" problem to give it a try. If/when I'm
convinced that this really was the problem (and that this is the right
fix), I'll send it upstream.
So, give it a try, and see what happens.
Matt
--
Matthew Dharm Home: [EMAIL PROTECTED]
Maintainer, Linux USB Mass Storage Driver
It was a new hope.
-- Dust Puppy
User Friendly, 12/25/1998
? .depend
? .scsiglue.o.flags
? .protocol.o.flags
? .transport.o.flags
? .usb.o.flags
? .initializers.o.flags
? .debug.o.flags
? .sddr09.o.flags
? .freecom.o.flags
? .dpcm.o.flags
Index: usb.c
===================================================================
RCS file: /cvsroot/linux-usb/storage/usb.c,v
retrieving revision 1.69
diff -u -r1.69 usb.c
--- usb.c 2001/11/11 03:33:03 1.69
+++ usb.c 2001/12/29 04:49:25
@@ -319,6 +319,13 @@
atomic_inc(¤t->files->count);
daemonize();
+ /* avoid getting signals */
+ spin_lock_irq(¤t->sigmask_lock);
+ flush_signals(current);
+ sigfillset(¤t->blocked);
+ recalc_sigpending(current);
+ spin_unlock_irq(¤t->sigmask_lock);
+
/* set our name for identification purposes */
sprintf(current->comm, "usb-storage-%d", us->host_number);
msg02087/pgp00000.pgp
Description: PGP signature
