Skip to contentSkip to conversation

Specialix/IO8

PATCH New Patrick van de Lageweg 1 participant 1 message Dec 8, 2004 Char and misc drivers

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Specialix/IO8

Hi,

This patch converts all save_flags/restore_flags to the new spin_lick_irqsave/spin_unlock_irqrestore calls, as well as some other 2.6.X cleanups. This allows the "io8+" driver to become SMP safe.

The large size of this patch comes mostly from the added debug features.

Patrick

drivers/char/Kconfig +1 -1
diff -u -r linux-2.6.10-rc3-clean/drivers/char/Kconfig linux-2.6.10-rc3-specialix/drivers/char/Kconfig
@@ -264,7 +264,7 @@
 
 config SPECIALIX
 	tristate "Specialix IO8+ card support"
-	depends on SERIAL_NONSTANDARD && BROKEN_ON_SMP
+	depends on SERIAL_NONSTANDARD
 	help
 	  This is a driver for the Specialix IO8+ multiport card (both the
 	  ISA and the PCI version) which gives you many serial ports. You
drivers/char/specialix.c +683 -271

2,014 lines not on this page · raw message

drivers/char/specialix_io8.h +4 -5
diff -u -r linux-2.6.10-rc3-clean/drivers/char/specialix_io8.h linux-2.6.10-rc3-specialix/drivers/char/specialix_io8.h
@@ -93,9 +93,11 @@
 	unsigned long   flags;
 	unsigned short	base;
 	unsigned char 	irq;
-	signed   char	count;
+	//signed   char	count;
+	int count;
 	unsigned char	DTR;
         int reg;
+	spinlock_t lock;
 };
 
 #define SX_BOARD_PRESENT	0x00000001
@@ -129,12 +131,9 @@
 	unsigned char		IER;
 	unsigned char		MSVR;
 	unsigned char		COR2;
-#ifdef SX_REPORT_OVERRUN
 	unsigned long		overrun;
-#endif	
-#ifdef SX_REPORT_FIFO
 	unsigned long		hits[10];
-#endif
+	spinlock_t lock;
 };
 
 #endif /* __KERNEL__ */