Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a5a1d1c2 authored by Thomas Gleixner's avatar Thomas Gleixner
Browse files

clocksource: Use a plain u64 instead of cycle_t



There is no point in having an extra type for extra confusion. u64 is
unambiguous.

Conversion was done with the following coccinelle script:

@rem@
@@
-typedef u64 cycle_t;

@Fix@
typedef cycle_t;
@@
-cycle_t
+u64

Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: John Stultz <john.stultz@linaro.org>
parent 7c0f6ba6
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -133,7 +133,7 @@ init_rtc_clockevent(void)
 * The QEMU clock as a clocksource primitive.
 */

static cycle_t
static u64
qemu_cs_read(struct clocksource *cs)
{
	return qemu_get_vmtime();
@@ -260,7 +260,7 @@ common_init_rtc(void)
 * use this method when WTINT is in use.
 */

static cycle_t read_rpcc(struct clocksource *cs)
static u64 read_rpcc(struct clocksource *cs)
{
	return rpcc();
}
+1 −1
Original line number Diff line number Diff line
@@ -268,7 +268,7 @@ static void __init timer_init(void)
/*
 * clocksource
 */
static cycle_t read_cycles(struct clocksource *cs)
static u64 read_cycles(struct clocksource *cs)
{
	struct timer_s *t = &timers[TID_CLOCKSOURCE];

+2 −2
Original line number Diff line number Diff line
@@ -59,13 +59,13 @@ static u64 notrace ep93xx_read_sched_clock(void)
	return ret;
}

cycle_t ep93xx_clocksource_read(struct clocksource *c)
u64 ep93xx_clocksource_read(struct clocksource *c)
{
	u64 ret;

	ret = readl(EP93XX_TIMER4_VALUE_LOW);
	ret |= ((u64) (readl(EP93XX_TIMER4_VALUE_HIGH) & 0xff) << 32);
	return (cycle_t) ret;
	return (u64) ret;
}

static int ep93xx_clkevt_set_next_event(unsigned long next,
+1 −1
Original line number Diff line number Diff line
@@ -19,7 +19,7 @@

#include "common.h"

static cycle_t cksrc_dc21285_read(struct clocksource *cs)
static u64 cksrc_dc21285_read(struct clocksource *cs)
{
	return cs->mask - *CSR_TIMER2_VALUE;
}
+1 −1
Original line number Diff line number Diff line
@@ -493,7 +493,7 @@ static u64 notrace ixp4xx_read_sched_clock(void)
 * clocksource
 */

static cycle_t ixp4xx_clocksource_read(struct clocksource *c)
static u64 ixp4xx_clocksource_read(struct clocksource *c)
{
	return *IXP4XX_OSTS;
}
Loading