eeh.h compile warnings / adbhid.c build failure

Olaf Hering olh at suse.de
Tue Mar 8 23:56:35 EST 2005


 On Thu, Mar 03, Benjamin Herrenschmidt wrote:

> There is no ADB bus on a G5, so the driver isn't useful anyway.
> Currently, ppc64 allows you to enable pmac drivers that won't build, but
> they also are useless on G5s. I'll fix that over time though.

They are of course not useless. Send this patch to Linus to allow the
mouse button emulation until either someone split it off the ADB driver,
or until someone fixes the stupid userinterfaces in Linux.


Signed-off-by: Olaf Hering <olh at suse.de>

diff -p -purN R/linux-2.6.3/drivers/macintosh/adb.c linux-2.6.3/drivers/macintosh/adb.c
--- R/linux-2.6.3/drivers/macintosh/adb.c	2004-02-18 04:59:56.000000000 +0100
+++ linux-2.6.3/drivers/macintosh/adb.c	2004-02-22 15:16:43.000000000 +0100
@@ -294,6 +294,10 @@ int __init adb_init(void)
 	if ( (_machine != _MACH_chrp) && (_machine != _MACH_Pmac) )
 		return 0;
 #endif
+#ifdef CONFIG_PPC64
+	if (_machine != _MACH_Pmac)
+		return 0;
+#endif
 #ifdef CONFIG_MAC
 	if (!MACH_IS_MAC)
 		return 0;
diff -p -purN R/linux-2.6.3/drivers/macintosh/adbhid.c linux-2.6.3/drivers/macintosh/adbhid.c
--- R/linux-2.6.3/drivers/macintosh/adbhid.c	2004-02-18 04:59:57.000000000 +0100
+++ linux-2.6.3/drivers/macintosh/adbhid.c	2004-02-22 15:41:34.000000000 +0100
@@ -1021,10 +1021,14 @@ init_ms_a3(int id)
 
 static int __init adbhid_init(void)
 {
-#ifndef CONFIG_MAC
+#ifdef CONFIG_PPC32
 	if ( (_machine != _MACH_chrp) && (_machine != _MACH_Pmac) )
 	    return 0;
 #endif
+#ifdef CONFIG_PPC64
+	if (_machine != _MACH_Pmac)
+		return 0;
+#endif
 
 	led_request.complete = 1;
 



More information about the Linuxppc64-dev mailing list