From: zippel@fh-brandenburg.de (Roman Zippel)
Subject: Re: L68K: 2.1.77 is out
To: linux-m68k@lists.linux-m68k.org
Date: Mon, 12 Jan 1998 13:28:44 +0100 (MET)
In-Reply-To: <Pine.LNX.3.96.980112100838.13924D-100000@mercator.cs.kuleuven.ac.be> from "Geert Uytterhoeven" at Jan 12, 98 10:13:52 am
Sender: owner-linux-m68k@phil.uni-sb.de

Hi,

> But at least here's the IDE fix (assembled by hand):

Here is an alternative fix for this, that hopefully will be
liked by the other architectures, too.

Roman

--- linux-2.1.77/drivers/block/ide.c.old	Fri Jan  9 03:08:10 1998
+++ linux-2.1.77/drivers/block/ide.c	Sat Jan 10 18:48:37 1998
@@ -1746,7 +1746,7 @@
 	ide_hwif_t *hwif = hwgroup->hwif;
 	ide_handler_t *handler;
 
-	if (!ide_ack_intr(hwif->io_ports[IDE_STATUS_OFFSET], hwif->io_ports[IDE_IRQ_OFFSET]))
+	if (!ide_ack_intr(hwif, hwif->io_ports[IDE_STATUS_OFFSET], hwif->io_ports[IDE_IRQ_OFFSET]))
 		return;
 
 	do {
--- linux-2.1.77/include/asm-m68k/ide.h.old	Fri Jan  9 03:08:21 1998
+++ linux-2.1.77/include/asm-m68k/ide.h	Mon Jan 12 10:44:35 1998
@@ -406,6 +406,8 @@
 #endif /* CONFIG_ATARI */
 }
 
+#define ide_ack_intr(hwif, base, irq) (hwif)->ack_intr((hwif))
+
 /*
  * On the Atari, we sometimes can't enable interrupts:
  */
--- linux-2.1.77/include/asm-ppc/ide.h.old	Thu Sep  4 21:54:49 1997
+++ linux-2.1.77/include/asm-ppc/ide.h	Sat Jan 10 18:51:46 1998
@@ -159,7 +159,7 @@
 /*
  * The following are not needed for the non-m68k ports
  */
-#define ide_ack_intr(base, irq)		(1)
+#define ide_ack_intr(hwif, base, irq)	(1)
 #define ide_release_lock(lock)		do {} while (0)
 #define ide_get_lock(lock, hdlr, data)	do {} while (0)
 
--- linux-2.1.77/include/asm-sparc64/ide.h.old	Thu Sep  4 21:54:49 1997
+++ linux-2.1.77/include/asm-sparc64/ide.h	Sat Jan 10 18:53:03 1998
@@ -100,7 +100,8 @@
 #undef  HD_DATA
 #define HD_DATA ((ide_ioreg_t)0)
 
-static __inline__ int ide_ack_intr(ide_ioreg_t status_port, ide_ioreg_t irq_port)
+static __inline__ int ide_ack_intr(ide_hwif_t *hwif, ide_ioreg_t status_port,
+				   ide_ioreg_t irq_port)
 {
 	unsigned char stat = inb(irq_port);
 
