From 90e3bc798bec8b33ba4300a7751b627b54b3bb5b Mon Sep 17 00:00:00 2001 From: Wei Yongjun Date: Mon, 3 Dec 2012 00:35:11 -0800 Subject: Use for_each_compatible_node() macro. Signed-off-by: Wei Yongjun Acked-by: Max Filippov Signed-off-by: Chris Zankel --- arch/xtensa/platforms/xtfpga/setup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/xtensa/platforms/xtfpga/setup.c b/arch/xtensa/platforms/xtfpga/setup.c index 71d61ca6a4af..237c36dc18b8 100644 --- a/arch/xtensa/platforms/xtfpga/setup.c +++ b/arch/xtensa/platforms/xtfpga/setup.c @@ -105,9 +105,9 @@ static void __init update_clock_frequency(struct device_node *node) static int __init machine_setup(void) { - struct device_node *serial = NULL; + struct device_node *serial; - while ((serial = of_find_compatible_node(serial, NULL, "ns16550a"))) + for_each_compatible_node(serial, NULL, "ns16550a") update_clock_frequency(serial); return 0; } -- cgit v1.2.3