mach-omap2: fix more arch_initcall() breakage
Remove more bogus arch_initcall() logic in mach-omap2/board-xyx.c files. They broke a multi-OMAP build I did, at *RUN TIME* not build time, since it tried to do the i2c init for every board linked in the kernel. Remember, init_machine() entries run at arch_initcall() time; that's where any board-specific init logic should normally go. Any initcalls in the mach-*/*c files should normally be guarded by tests to make sure they only run on the relevant hardware (board, cpu). Better yet, get rid of the initcalls; init_machine() can *explicitly* call the right version of that code, and pass in board-specific config data; and there are hooks that can handle cpu-specific stuff too. A quick glance suggests most of the remaining initcall logic in the mach-omap2 directory is similarly broken... this patch gets rid of one frequently-cloned idiom, it should help. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
Showing
Please register or sign in to comment