summaryrefslogtreecommitdiffstats
path: root/drivers/macintosh/windfarm_core.c
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2006-03-03 17:03:21 +1100
committerPaul Mackerras <paulus@samba.org>2006-03-03 21:43:53 +1100
commitb55fafc5a800f27beedfdcf8bd1b6baa47e769a9 (patch)
treedc651c5738f20b72cb17ef3fc33e2e27977e6372 /drivers/macintosh/windfarm_core.c
parent0c2aca88bdac4254a13466fb108733d243a118b6 (diff)
downloadtalos-op-linux-b55fafc5a800f27beedfdcf8bd1b6baa47e769a9.tar.gz
talos-op-linux-b55fafc5a800f27beedfdcf8bd1b6baa47e769a9.zip
[PATCH] powerpc: Fix old g5 issues with windfarm
Some of the windfarm sensor modules can initialize on old machines that don't have full windfarm support like non-dual core desktop G5s. Unfortunately, by doing so, they would trigger a bug in their matching algorithm causing them to attach to the wrong bus, thus triggering issues with the i2c core and breaking the thermal driver. This patch fixes the probing issue (so that they will work when a windfarm port is done to these machines) and also prevents for now windfarm to load at all on these machines that still use therm_pm72 to avoid wasting resources. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'drivers/macintosh/windfarm_core.c')
-rw-r--r--drivers/macintosh/windfarm_core.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/macintosh/windfarm_core.c b/drivers/macintosh/windfarm_core.c
index bb8d5efe19bf..6c0ba04bc57a 100644
--- a/drivers/macintosh/windfarm_core.c
+++ b/drivers/macintosh/windfarm_core.c
@@ -35,6 +35,8 @@
#include <linux/platform_device.h>
#include <linux/mutex.h>
+#include <asm/prom.h>
+
#include "windfarm.h"
#define VERSION "0.2"
@@ -465,6 +467,11 @@ static int __init windfarm_core_init(void)
{
DBG("wf: core loaded\n");
+ /* Don't register on old machines that use therm_pm72 for now */
+ if (machine_is_compatible("PowerMac7,2") ||
+ machine_is_compatible("PowerMac7,3") ||
+ machine_is_compatible("RackMac3,1"))
+ return -ENODEV;
platform_device_register(&wf_platform_device);
return 0;
}
OpenPOWER on IntegriCloud