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

xtensa: Remove unnecessary of_platform_populate with default match table

After patch "of/platform: Add common method to populate default bus",
it is possible for arch code to remove unnecessary callers of
of_platform_populate with default match table.

Move of_clk_init() into time_init(), then drop xtensa_device_probe() fully.

Cc: Chris Zankel <chris@zankel.net>
Cc: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Kefeng Wang <wangkefeng.wang@huawei.com>
Signed-off-by: Rob Herring <robh@kernel.org>

authored by

Kefeng Wang and committed by
Rob Herring
69d99e6c 2b658932

+2 -11
-11
arch/xtensa/kernel/setup.c
··· 22 22 #include <linux/bootmem.h> 23 23 #include <linux/kernel.h> 24 24 #include <linux/percpu.h> 25 - #include <linux/clk-provider.h> 26 25 #include <linux/cpu.h> 27 26 #include <linux/of_fdt.h> 28 - #include <linux/of_platform.h> 29 27 30 28 #if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_DUMMY_CONSOLE) 31 29 # include <linux/console.h> ··· 249 251 if (!command_line[0]) 250 252 strlcpy(command_line, boot_command_line, COMMAND_LINE_SIZE); 251 253 } 252 - 253 - static int __init xtensa_device_probe(void) 254 - { 255 - of_clk_init(NULL); 256 - of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL); 257 - return 0; 258 - } 259 - 260 - device_initcall(xtensa_device_probe); 261 254 262 255 #endif /* CONFIG_OF */ 263 256
+2
arch/xtensa/kernel/time.c
··· 15 15 #include <linux/errno.h> 16 16 #include <linux/sched.h> 17 17 #include <linux/time.h> 18 + #include <linux/clk-provider.h> 18 19 #include <linux/clocksource.h> 19 20 #include <linux/clockchips.h> 20 21 #include <linux/interrupt.h> ··· 149 148 local_timer_setup(0); 150 149 setup_irq(this_cpu_ptr(&ccount_timer)->evt.irq, &timer_irqaction); 151 150 sched_clock_register(ccount_sched_clock_read, 32, ccount_freq); 151 + of_clk_init(NULL); 152 152 clocksource_probe(); 153 153 } 154 154