From: Anton Vorontsov Date: Tue, 8 Jul 2008 17:36:40 +0000 (+0400) Subject: powerpc/fsl_soc: gianfar: don't probe disabled devices X-Git-Tag: v2.6.27-rc1~865^2~41 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=69ad7e73dee33f8e0680825006c801ca6b4bf470;p=linux-2.6-omap-h63xx.git powerpc/fsl_soc: gianfar: don't probe disabled devices Freescale ships MPC8315E-RDB boards in two variants: 1. With TSEC1 ethernet support and USB UTMI PHY; 2. Without TSEC1 support, but with USB ULPI PHY in addition. For the second case U-Boot will add status = "disabled"; property into the TSEC1 node, so Linux should not try to probe it. Signed-off-by: Anton Vorontsov Signed-off-by: Kumar Gala --- diff --git a/arch/powerpc/sysdev/fsl_soc.c b/arch/powerpc/sysdev/fsl_soc.c index ebcec7362f9..ca180a93bca 100644 --- a/arch/powerpc/sysdev/fsl_soc.c +++ b/arch/powerpc/sysdev/fsl_soc.c @@ -296,6 +296,9 @@ static int __init gfar_of_init(void) const phandle *ph; int n_res = 2; + if (!of_device_is_available(np)) + continue; + memset(r, 0, sizeof(r)); memset(&gfar_data, 0, sizeof(gfar_data));