diff options
author | Rob Herring <rob.herring@calxeda.com> | 2013-02-06 21:40:22 +0100 |
---|---|---|
committer | Rob Herring <rob.herring@calxeda.com> | 2013-03-11 14:42:07 +0100 |
commit | effbfdd7baf7babc73154b87a5ff940969cf6559 (patch) | |
tree | 7aab87a4f5be6ed1ab817cdd65dcd4d983094e37 /drivers/clocksource/bcm2835_timer.c | |
parent | clocksource: add empty version of clocksource_of_init (diff) | |
download | linux-effbfdd7baf7babc73154b87a5ff940969cf6559.tar.xz linux-effbfdd7baf7babc73154b87a5ff940969cf6559.zip |
clocksource: pass DT node pointer to init functions
In cases where we have multiple nodes of the same type, we may need the
node pointer to know which node was matched. Passing the node pointer
also keeps the init function from having to match the node a 2nd time.
Update bcm2835, vt8500, and tegra20 init functions for the new function
prototype. Further tegra20 clean-ups are in follow-up commit.
Signed-off-by: Rob Herring <rob.herring@calxeda.com>
Cc: John Stultz <johnstul@us.ibm.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Stephen Warren <swarren@nvidia.com>
Tested-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Tony Prisk <linux@prisktech.co.nz>
Tested-by: Michal Simek <michal.simek@xilinx.com>
Diffstat (limited to 'drivers/clocksource/bcm2835_timer.c')
-rw-r--r-- | drivers/clocksource/bcm2835_timer.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/drivers/clocksource/bcm2835_timer.c b/drivers/clocksource/bcm2835_timer.c index 50c68fef944b..766611d29945 100644 --- a/drivers/clocksource/bcm2835_timer.c +++ b/drivers/clocksource/bcm2835_timer.c @@ -95,23 +95,13 @@ static irqreturn_t bcm2835_time_interrupt(int irq, void *dev_id) } } -static struct of_device_id bcm2835_time_match[] __initconst = { - { .compatible = "brcm,bcm2835-system-timer" }, - {} -}; - -static void __init bcm2835_timer_init(void) +static void __init bcm2835_timer_init(struct device_node *node) { - struct device_node *node; void __iomem *base; u32 freq; int irq; struct bcm2835_timer *timer; - node = of_find_matching_node(NULL, bcm2835_time_match); - if (!node) - panic("No bcm2835 timer node"); - base = of_iomap(node, 0); if (!base) panic("Can't remap registers"); |