Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 295798
b: refs/heads/master
c: 23e5bc0
h: refs/heads/master
v: v3
  • Loading branch information
Magnus Damm authored and Rafael J. Wysocki committed Mar 12, 2012
1 parent 740e663 commit b22ccea
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 3be26fdba82a2ae8ed568ab5d4a0a2e252f18b13
refs/heads/master: 23e5bc03e3b07185d61c212bf39aaf126cc958e3
18 changes: 11 additions & 7 deletions trunk/arch/arm/mach-shmobile/board-bonito.c
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ static void __init bonito_init(void)
}
}

static void __init bonito_timer_init(void)
static void __init bonito_earlytimer_init(void)
{
u16 val;
u8 md_ck = 0;
Expand All @@ -481,18 +481,22 @@ static void __init bonito_timer_init(void)
md_ck |= MD_CK0;

r8a7740_clock_init(md_ck);
shmobile_timer.init();
shmobile_earlytimer_init();
}

struct sys_timer bonito_timer = {
.init = bonito_timer_init,
};
void __init bonito_add_early_devices(void)
{
r8a7740_add_early_devices();

/* override timer setup with board-specific code */
shmobile_timer.init = bonito_earlytimer_init;
}

MACHINE_START(BONITO, "bonito")
.map_io = bonito_map_io,
.init_early = r8a7740_add_early_devices,
.init_early = bonito_add_early_devices,
.init_irq = r8a7740_init_irq,
.handle_irq = shmobile_handle_irq_intc,
.init_machine = bonito_init,
.timer = &bonito_timer,
.timer = &shmobile_timer,
MACHINE_END
10 changes: 10 additions & 0 deletions trunk/arch/arm/mach-shmobile/setup-r8a7740.c
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
#include <asm/mach-types.h>
#include <asm/mach/map.h>
#include <asm/mach/arch.h>
#include <asm/mach/time.h>

static struct map_desc r8a7740_io_desc[] __initdata = {
/*
Expand Down Expand Up @@ -377,11 +378,20 @@ void __init r8a7740_add_standard_devices(void)
ARRAY_SIZE(r8a7740_late_devices));
}

static void __init r8a7740_earlytimer_init(void)
{
r8a7740_clock_init(0);
shmobile_earlytimer_init();
}

void __init r8a7740_add_early_devices(void)
{
early_platform_add_devices(r8a7740_early_devices,
ARRAY_SIZE(r8a7740_early_devices));

/* setup early console here as well */
shmobile_setup_console();

/* override timer setup with soc-specific code */
shmobile_timer.init = r8a7740_earlytimer_init;
}

0 comments on commit b22ccea

Please sign in to comment.