patch-1.3.100 linux/drivers/char/msbusmouse.c

Next file: linux/drivers/char/random.c
Previous file: linux/drivers/char/ChangeLog
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v1.3.99/linux/drivers/char/msbusmouse.c linux/drivers/char/msbusmouse.c
@@ -47,6 +47,13 @@
 #include <asm/irq.h>
 
 static struct mouse_status mouse;
+static int mouse_irq = MOUSE_IRQ;
+
+void msmouse_setup(char *str, int *ints)
+{
+	if (ints[0] > 0)
+		mouse_irq=ints[1];
+}
 
 static void ms_mouse_interrupt(int irq, void *dev_id, struct pt_regs * regs)
 {
@@ -97,7 +104,7 @@
 		return;
 	MS_MSE_INT_OFF();
 	mouse.ready = 0; 
-	free_irq(MOUSE_IRQ, NULL);
+	free_irq(mouse_irq, NULL);
 	MOD_DEC_USE_COUNT;
 }
 
@@ -107,7 +114,7 @@
 		return -EINVAL;
 	if (mouse.active++)
 		return 0;
-	if (request_irq(MOUSE_IRQ, ms_mouse_interrupt, 0, "MS Busmouse", NULL)) {
+	if (request_irq(mouse_irq, ms_mouse_interrupt, 0, "MS Busmouse", NULL)) {
 		mouse.active--;
 		return -EBUSY;
 	}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov with Sam's (original) version
of this