patch-2.3.99-pre9 linux/include/asm-sh/ide.h

Next file: linux/include/asm-sh/io.h
Previous file: linux/include/asm-sh/hitachi_se.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.99-pre8/linux/include/asm-sh/ide.h linux/include/asm-sh/ide.h
@@ -17,7 +17,7 @@
 #include <linux/config.h>
 
 #ifndef MAX_HWIFS
-#define MAX_HWIFS	1	/* XXX: For my board -- gniibe */
+#define MAX_HWIFS	1
 #endif
 
 #define ide__sti()	__sti()
@@ -25,8 +25,8 @@
 static __inline__ int ide_default_irq(ide_ioreg_t base)
 {
 	switch (base) {
-		case 0xba0001f0: return 14;
-		case 0xba000170: return 14;
+		case 0x01f0: return 14;
+		case 0x0170: return 15;
 		default:
 			return 0;
 	}
@@ -36,9 +36,9 @@
 {
 	switch (index) {
 		case 0:	
-			return 0xba0001f0;
+			return 0x01f0;
 		case 1:	
-			return 0xba000170;
+			return 0x0170;
 		default:
 			return 0;
 	}
@@ -69,6 +69,7 @@
 	int index;
 
 	for(index = 0; index < MAX_HWIFS; index++) {
+		memset(&hw, 0, sizeof(hw_regs_t));
 		ide_init_hwif_ports(&hw, ide_default_io_base(index), 0, NULL);
 		hw.irq = ide_default_irq(ide_default_io_base(index));
 		ide_register_hw(&hw, NULL);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)