Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 249916
b: refs/heads/master
c: d6e15d7
h: refs/heads/master
v: v3
  • Loading branch information
Russell King committed May 23, 2011
1 parent 74735a6 commit 3ecf052
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 15 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: c5039f52329ff796d7fea9024e5615abee02dbfb
refs/heads/master: d6e15d78537d2483bff05f0ee5b5cec6c4678fd5
1 change: 1 addition & 0 deletions trunk/arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -884,6 +884,7 @@ config PLAT_SPEAR
select ARM_AMBA
select ARCH_REQUIRE_GPIOLIB
select CLKDEV_LOOKUP
select CLKSRC_MMIO
select GENERIC_CLOCKEVENTS
select HAVE_CLK
help
Expand Down
16 changes: 2 additions & 14 deletions trunk/arch/arm/plat-spear/time.c
Original file line number Diff line number Diff line change
Expand Up @@ -70,19 +70,6 @@ static void clockevent_set_mode(enum clock_event_mode mode,
static int clockevent_next_event(unsigned long evt,
struct clock_event_device *clk_event_dev);

static cycle_t clocksource_read_cycles(struct clocksource *cs)
{
return (cycle_t) readw(gpt_base + COUNT(CLKSRC));
}

static struct clocksource clksrc = {
.name = "tmr1",
.rating = 200, /* its a pretty decent clock */
.read = clocksource_read_cycles,
.mask = 0xFFFF, /* 16 bits */
.flags = CLOCK_SOURCE_IS_CONTINUOUS,
};

static void spear_clocksource_init(void)
{
u32 tick_rate;
Expand All @@ -103,7 +90,8 @@ static void spear_clocksource_init(void)
writew(val, gpt_base + CR(CLKSRC));

/* register the clocksource */
clocksource_register_hz(&clksrc, tick_rate);
clocksource_mmio_init(gpt_base + COUNT(CLKSRC), "tmr1", tick_rate,
200, 16, clocksource_mmio_readw_up);
}

static struct clock_event_device clkevt = {
Expand Down

0 comments on commit 3ecf052

Please sign in to comment.