From: Russell King Date: Thu, 16 Dec 2010 13:49:34 +0000 (+0000) Subject: ARM: provide an early platform initialization hook X-Git-Tag: v2.6.38-rc1~471^2~2^2~5 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=dec12e62c03d26bbc7a142f067215a3a43cce7d0;p=platform%2Fupstream%2Fkernel-adaptation-pc.git ARM: provide an early platform initialization hook This allows platforms to hook into the initialization early to setup things like scheduler clocks, etc. Signed-off-by: Russell King --- diff --git a/arch/arm/include/asm/mach/arch.h b/arch/arm/include/asm/mach/arch.h index 69908dd..3a0893a 100644 --- a/arch/arm/include/asm/mach/arch.h +++ b/arch/arm/include/asm/mach/arch.h @@ -37,6 +37,7 @@ struct machine_desc { struct meminfo *); void (*reserve)(void);/* reserve mem blocks */ void (*map_io)(void);/* IO mapping function */ + void (*init_early)(void); void (*init_irq)(void); struct sys_timer *timer; /* system tick timer */ void (*init_machine)(void); diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c index e53132e..3455ad3 100644 --- a/arch/arm/kernel/setup.c +++ b/arch/arm/kernel/setup.c @@ -880,6 +880,9 @@ void __init setup_arch(char **cmdline_p) #endif #endif early_trap_init(); + + if (mdesc->init_early) + mdesc->init_early(); }