From: Gerlando Falauto Date: Fri, 7 Dec 2012 15:09:15 +0000 (+0100) Subject: powerpc/83xx: apply mpc8360e quirk for kmeter1 only when par_io is present X-Git-Tag: firefly_0821_release~3680^2~1053^2~2^2~10 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=9c2f451e0db90d257c745df1d967c8010f14f0dd;p=firefly-linux-kernel-4.4.55.git powerpc/83xx: apply mpc8360e quirk for kmeter1 only when par_io is present There is no point in applying this quirk when par_io is not present. Signed-off-by: Gerlando Falauto Signed-off-by: Holger Brunck Signed-off-by: Kumar Gala --- diff --git a/arch/powerpc/platforms/83xx/km83xx.c b/arch/powerpc/platforms/83xx/km83xx.c index 88b1af04661b..bf4c4473abb9 100644 --- a/arch/powerpc/platforms/83xx/km83xx.c +++ b/arch/powerpc/platforms/83xx/km83xx.c @@ -148,11 +148,13 @@ static void __init mpc83xx_km_setup_arch(void) for_each_node_by_name(np, "ucc") par_io_of_config(np); - } - np = of_find_compatible_node(NULL, "network", "ucc_geth"); - if (np != NULL) { - quirk_mpc8360e_qe_enet10(); - of_node_put(np); + + /* Only apply this quirk when par_io is available */ + np = of_find_compatible_node(NULL, "network", "ucc_geth"); + if (np != NULL) { + quirk_mpc8360e_qe_enet10(); + of_node_put(np); + } } #endif /* CONFIG_QUICC_ENGINE */ }