patch-2.1.100 linux/drivers/misc/parport_share.c
Next file: linux/drivers/net/3c509.c
Previous file: linux/drivers/misc/parport_procfs.c
Back to the patch index
Back to the overall index
- Lines: 22
- Date:
Mon May 4 11:03:09 1998
- Orig file:
v2.1.99/linux/drivers/misc/parport_share.c
- Orig date:
Sat Apr 25 18:13:11 1998
diff -u --recursive --new-file v2.1.99/linux/drivers/misc/parport_share.c linux/drivers/misc/parport_share.c
@@ -308,7 +308,9 @@
}
/* Now we do the change of devices */
+ spin_lock_irqsave(&port->lock, flags);
port->cad = dev;
+ spin_unlock_irqrestore(&port->lock, flags);
/* Swap the IRQ handlers. */
if (port->irq != PARPORT_IRQ_NONE) {
@@ -346,9 +348,8 @@
dev->waitprev = port->waittail;
if (port->waittail)
port->waittail->waitnext = dev;
- else {
- port->waithead = dev->port->waittail = dev;
- }
+ else
+ port->waithead = port->waittail = dev;
}
spin_unlock_irqrestore (&port->lock, flags);
}
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov