Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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 <gerlando.falauto@keymile.com>
Signed-off-by: Holger Brunck <holger.brunck@keymile.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>

authored by

Gerlando Falauto and committed by
Kumar Gala
9c2f451e 14f40f31

+7 -5
+7 -5
arch/powerpc/platforms/83xx/km83xx.c
··· 148 148 149 149 for_each_node_by_name(np, "ucc") 150 150 par_io_of_config(np); 151 - } 152 - np = of_find_compatible_node(NULL, "network", "ucc_geth"); 153 - if (np != NULL) { 154 - quirk_mpc8360e_qe_enet10(); 155 - of_node_put(np); 151 + 152 + /* Only apply this quirk when par_io is available */ 153 + np = of_find_compatible_node(NULL, "network", "ucc_geth"); 154 + if (np != NULL) { 155 + quirk_mpc8360e_qe_enet10(); 156 + of_node_put(np); 157 + } 156 158 } 157 159 #endif /* CONFIG_QUICC_ENGINE */ 158 160 }