Skip to content

Commit

Permalink
clocksource: armada-370-xp: Use CLOCKSOURCE_OF_DECLARE
Browse files Browse the repository at this point in the history
This is almost cosmetic: we achieve a bit of consistency with
other clocksource drivers by using the CLOCKSOURCE_OF_DECLARE
macro for the boilerplate code.

Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
Signed-off-by: Daniel Lezcano <daniel.lezcano@linaro.org>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
  • Loading branch information
Ezequiel Garcia authored and Daniel Lezcano committed Sep 2, 2013
1 parent 3579698 commit 573145f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 23 deletions.
4 changes: 2 additions & 2 deletions arch/arm/mach-mvebu/armada-370-xp.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
#include <linux/of_address.h>
#include <linux/of_platform.h>
#include <linux/io.h>
#include <linux/time-armada-370-xp.h>
#include <linux/clocksource.h>
#include <linux/dma-mapping.h>
#include <linux/mbus.h>
#include <asm/hardware/cache-l2x0.h>
Expand Down Expand Up @@ -69,7 +69,7 @@ static void __init armada_370_xp_mbus_init(void)
static void __init armada_370_xp_timer_and_clk_init(void)
{
of_clk_init(NULL);
armada_370_xp_timer_init();
clocksource_of_init();
coherency_init();
armada_370_xp_mbus_init();
#ifdef CONFIG_CACHE_L2X0
Expand Down
6 changes: 3 additions & 3 deletions drivers/clocksource/time-armada-370-xp.c
Original file line number Diff line number Diff line change
Expand Up @@ -212,13 +212,11 @@ static struct local_timer_ops armada_370_xp_local_timer_ops = {
.stop = armada_370_xp_timer_stop,
};

void __init armada_370_xp_timer_init(void)
static void __init armada_370_xp_timer_init(struct device_node *np)
{
u32 clr = 0, set = 0;
struct device_node *np;
int res;

np = of_find_compatible_node(NULL, NULL, "marvell,armada-370-xp-timer");
timer_base = of_iomap(np, 0);
WARN_ON(!timer_base);
local_base = of_iomap(np, 1);
Expand Down Expand Up @@ -290,3 +288,5 @@ void __init armada_370_xp_timer_init(void)
#endif
}
}
CLOCKSOURCE_OF_DECLARE(armada_370_xp, "marvell,armada-370-xp-timer",
armada_370_xp_timer_init);
18 changes: 0 additions & 18 deletions include/linux/time-armada-370-xp.h

This file was deleted.

0 comments on commit 573145f

Please sign in to comment.