[PATCH 06/10] ARM: bcm2835: register the clocksource device earlier
Andre Heider
a.heider at gmail.com
Sat Oct 19 08:20:51 EDT 2013
RPi's mailbox driver is used early and it needs clock functions to
handle timeouts.
Register the driver straight after its clkdev.
Signed-off-by: Andre Heider <a.heider at gmail.com>
---
arch/arm/mach-bcm2835/core.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/arch/arm/mach-bcm2835/core.c b/arch/arm/mach-bcm2835/core.c
index 6835960..cba7bf6 100644
--- a/arch/arm/mach-bcm2835/core.c
+++ b/arch/arm/mach-bcm2835/core.c
@@ -45,6 +45,8 @@ static int bcm2835_clk_init(void)
clk = clk_fixed("bcm2835-cs", 1 * 1000 * 1000);
clk_register_clkdev(clk, NULL, "bcm2835-cs");
+ add_generic_device("bcm2835-cs", DEVICE_ID_SINGLE, NULL, BCM2835_ST_BASE, 0x1C, IORESOURCE_MEM, NULL);
+
return 0;
}
postcore_initcall(bcm2835_clk_init);
@@ -52,7 +54,6 @@ postcore_initcall(bcm2835_clk_init);
static int bcm2835_dev_init(void)
{
add_generic_device("bcm2835-gpio", 0, NULL, BCM2835_GPIO_BASE, 0xB0, IORESOURCE_MEM, NULL);
- add_generic_device("bcm2835-cs", DEVICE_ID_SINGLE, NULL, BCM2835_ST_BASE, 0x1C, IORESOURCE_MEM, NULL);
add_generic_device("bcm2835_mci", 0, NULL, BCM2835_EMMC_BASE, 0xFC, IORESOURCE_MEM, NULL);
return 0;
}
--
1.8.3.2
More information about the barebox
mailing list