diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2016-12-21 14:32:01 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2016-12-25 05:04:12 -0500 |
commit | a5a1d1c2914b5316924c7893eb683a5420ebd3be (patch) | |
tree | 9078b8a179031e7e8b320e1c69f182cc285e7b5d /arch/mips | |
parent | 7c0f6ba682b9c7632072ffbedf8d328c8f3c42ba (diff) |
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: Thomas Gleixner <tglx@linutronix.de>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: John Stultz <john.stultz@linaro.org>
Diffstat (limited to 'arch/mips')
-rw-r--r-- | arch/mips/alchemy/common/time.c | 2 | ||||
-rw-r--r-- | arch/mips/cavium-octeon/csrc-octeon.c | 2 | ||||
-rw-r--r-- | arch/mips/jz4740/time.c | 2 | ||||
-rw-r--r-- | arch/mips/kernel/cevt-txx9.c | 2 | ||||
-rw-r--r-- | arch/mips/kernel/csrc-bcm1480.c | 4 | ||||
-rw-r--r-- | arch/mips/kernel/csrc-ioasic.c | 2 | ||||
-rw-r--r-- | arch/mips/kernel/csrc-r4k.c | 2 | ||||
-rw-r--r-- | arch/mips/kernel/csrc-sb1250.c | 4 | ||||
-rw-r--r-- | arch/mips/loongson32/common/time.c | 4 | ||||
-rw-r--r-- | arch/mips/loongson64/common/cs5536/cs5536_mfgpt.c | 4 | ||||
-rw-r--r-- | arch/mips/loongson64/loongson-3/hpet.c | 4 | ||||
-rw-r--r-- | arch/mips/mti-malta/malta-time.c | 2 | ||||
-rw-r--r-- | arch/mips/netlogic/common/time.c | 4 | ||||
-rw-r--r-- | arch/mips/sgi-ip27/ip27-timer.c | 2 |
14 files changed, 20 insertions, 20 deletions
diff --git a/arch/mips/alchemy/common/time.c b/arch/mips/alchemy/common/time.c index f99d3ec17a45..e1bec5a77c39 100644 --- a/arch/mips/alchemy/common/time.c +++ b/arch/mips/alchemy/common/time.c | |||
@@ -44,7 +44,7 @@ | |||
44 | /* 32kHz clock enabled and detected */ | 44 | /* 32kHz clock enabled and detected */ |
45 | #define CNTR_OK (SYS_CNTRL_E0 | SYS_CNTRL_32S) | 45 | #define CNTR_OK (SYS_CNTRL_E0 | SYS_CNTRL_32S) |
46 | 46 | ||
47 | static cycle_t au1x_counter1_read(struct clocksource *cs) | 47 | static u64 au1x_counter1_read(struct clocksource *cs) |
48 | { | 48 | { |
49 | return alchemy_rdsys(AU1000_SYS_RTCREAD); | 49 | return alchemy_rdsys(AU1000_SYS_RTCREAD); |
50 | } | 50 | } |
diff --git a/arch/mips/cavium-octeon/csrc-octeon.c b/arch/mips/cavium-octeon/csrc-octeon.c index 23c2344a3552..39f153fe0022 100644 --- a/arch/mips/cavium-octeon/csrc-octeon.c +++ b/arch/mips/cavium-octeon/csrc-octeon.c | |||
@@ -98,7 +98,7 @@ void octeon_init_cvmcount(void) | |||
98 | local_irq_restore(flags); | 98 | local_irq_restore(flags); |
99 | } | 99 | } |
100 | 100 | ||
101 | static cycle_t octeon_cvmcount_read(struct clocksource *cs) | 101 | static u64 octeon_cvmcount_read(struct clocksource *cs) |
102 | { | 102 | { |
103 | return read_c0_cvmcount(); | 103 | return read_c0_cvmcount(); |
104 | } | 104 | } |
diff --git a/arch/mips/jz4740/time.c b/arch/mips/jz4740/time.c index 1f7ca2c9f262..bcf8f8c62737 100644 --- a/arch/mips/jz4740/time.c +++ b/arch/mips/jz4740/time.c | |||
@@ -34,7 +34,7 @@ | |||
34 | 34 | ||
35 | static uint16_t jz4740_jiffies_per_tick; | 35 | static uint16_t jz4740_jiffies_per_tick; |
36 | 36 | ||
37 | static cycle_t jz4740_clocksource_read(struct clocksource *cs) | 37 | static u64 jz4740_clocksource_read(struct clocksource *cs) |
38 | { | 38 | { |
39 | return jz4740_timer_get_count(TIMER_CLOCKSOURCE); | 39 | return jz4740_timer_get_count(TIMER_CLOCKSOURCE); |
40 | } | 40 | } |
diff --git a/arch/mips/kernel/cevt-txx9.c b/arch/mips/kernel/cevt-txx9.c index 537eefdf838f..aaca60d6ffc3 100644 --- a/arch/mips/kernel/cevt-txx9.c +++ b/arch/mips/kernel/cevt-txx9.c | |||
@@ -27,7 +27,7 @@ struct txx9_clocksource { | |||
27 | struct txx9_tmr_reg __iomem *tmrptr; | 27 | struct txx9_tmr_reg __iomem *tmrptr; |
28 | }; | 28 | }; |
29 | 29 | ||
30 | static cycle_t txx9_cs_read(struct clocksource *cs) | 30 | static u64 txx9_cs_read(struct clocksource *cs) |
31 | { | 31 | { |
32 | struct txx9_clocksource *txx9_cs = | 32 | struct txx9_clocksource *txx9_cs = |
33 | container_of(cs, struct txx9_clocksource, cs); | 33 | container_of(cs, struct txx9_clocksource, cs); |
diff --git a/arch/mips/kernel/csrc-bcm1480.c b/arch/mips/kernel/csrc-bcm1480.c index 7f65b53d1b24..f011261e9506 100644 --- a/arch/mips/kernel/csrc-bcm1480.c +++ b/arch/mips/kernel/csrc-bcm1480.c | |||
@@ -25,9 +25,9 @@ | |||
25 | 25 | ||
26 | #include <asm/sibyte/sb1250.h> | 26 | #include <asm/sibyte/sb1250.h> |
27 | 27 | ||
28 | static cycle_t bcm1480_hpt_read(struct clocksource *cs) | 28 | static u64 bcm1480_hpt_read(struct clocksource *cs) |
29 | { | 29 | { |
30 | return (cycle_t) __raw_readq(IOADDR(A_SCD_ZBBUS_CYCLE_COUNT)); | 30 | return (u64) __raw_readq(IOADDR(A_SCD_ZBBUS_CYCLE_COUNT)); |
31 | } | 31 | } |
32 | 32 | ||
33 | struct clocksource bcm1480_clocksource = { | 33 | struct clocksource bcm1480_clocksource = { |
diff --git a/arch/mips/kernel/csrc-ioasic.c b/arch/mips/kernel/csrc-ioasic.c index 722f5589cd1d..f6acd1e58c26 100644 --- a/arch/mips/kernel/csrc-ioasic.c +++ b/arch/mips/kernel/csrc-ioasic.c | |||
@@ -22,7 +22,7 @@ | |||
22 | #include <asm/dec/ioasic.h> | 22 | #include <asm/dec/ioasic.h> |
23 | #include <asm/dec/ioasic_addrs.h> | 23 | #include <asm/dec/ioasic_addrs.h> |
24 | 24 | ||
25 | static cycle_t dec_ioasic_hpt_read(struct clocksource *cs) | 25 | static u64 dec_ioasic_hpt_read(struct clocksource *cs) |
26 | { | 26 | { |
27 | return ioasic_read(IO_REG_FCTR); | 27 | return ioasic_read(IO_REG_FCTR); |
28 | } | 28 | } |
diff --git a/arch/mips/kernel/csrc-r4k.c b/arch/mips/kernel/csrc-r4k.c index d76275da54cb..eed099f35bf1 100644 --- a/arch/mips/kernel/csrc-r4k.c +++ b/arch/mips/kernel/csrc-r4k.c | |||
@@ -11,7 +11,7 @@ | |||
11 | 11 | ||
12 | #include <asm/time.h> | 12 | #include <asm/time.h> |
13 | 13 | ||
14 | static cycle_t c0_hpt_read(struct clocksource *cs) | 14 | static u64 c0_hpt_read(struct clocksource *cs) |
15 | { | 15 | { |
16 | return read_c0_count(); | 16 | return read_c0_count(); |
17 | } | 17 | } |
diff --git a/arch/mips/kernel/csrc-sb1250.c b/arch/mips/kernel/csrc-sb1250.c index d915652b4d56..b07b7310d3f4 100644 --- a/arch/mips/kernel/csrc-sb1250.c +++ b/arch/mips/kernel/csrc-sb1250.c | |||
@@ -30,7 +30,7 @@ | |||
30 | * The HPT is free running from SB1250_HPT_VALUE down to 0 then starts over | 30 | * The HPT is free running from SB1250_HPT_VALUE down to 0 then starts over |
31 | * again. | 31 | * again. |
32 | */ | 32 | */ |
33 | static inline cycle_t sb1250_hpt_get_cycles(void) | 33 | static inline u64 sb1250_hpt_get_cycles(void) |
34 | { | 34 | { |
35 | unsigned int count; | 35 | unsigned int count; |
36 | void __iomem *addr; | 36 | void __iomem *addr; |
@@ -41,7 +41,7 @@ static inline cycle_t sb1250_hpt_get_cycles(void) | |||
41 | return SB1250_HPT_VALUE - count; | 41 | return SB1250_HPT_VALUE - count; |
42 | } | 42 | } |
43 | 43 | ||
44 | static cycle_t sb1250_hpt_read(struct clocksource *cs) | 44 | static u64 sb1250_hpt_read(struct clocksource *cs) |
45 | { | 45 | { |
46 | return sb1250_hpt_get_cycles(); | 46 | return sb1250_hpt_get_cycles(); |
47 | } | 47 | } |
diff --git a/arch/mips/loongson32/common/time.c b/arch/mips/loongson32/common/time.c index ff224f0020e5..e6f972d35252 100644 --- a/arch/mips/loongson32/common/time.c +++ b/arch/mips/loongson32/common/time.c | |||
@@ -63,7 +63,7 @@ void __init ls1x_pwmtimer_init(void) | |||
63 | ls1x_pwmtimer_restart(); | 63 | ls1x_pwmtimer_restart(); |
64 | } | 64 | } |
65 | 65 | ||
66 | static cycle_t ls1x_clocksource_read(struct clocksource *cs) | 66 | static u64 ls1x_clocksource_read(struct clocksource *cs) |
67 | { | 67 | { |
68 | unsigned long flags; | 68 | unsigned long flags; |
69 | int count; | 69 | int count; |
@@ -107,7 +107,7 @@ static cycle_t ls1x_clocksource_read(struct clocksource *cs) | |||
107 | 107 | ||
108 | raw_spin_unlock_irqrestore(&ls1x_timer_lock, flags); | 108 | raw_spin_unlock_irqrestore(&ls1x_timer_lock, flags); |
109 | 109 | ||
110 | return (cycle_t) (jifs * ls1x_jiffies_per_tick) + count; | 110 | return (u64) (jifs * ls1x_jiffies_per_tick) + count; |
111 | } | 111 | } |
112 | 112 | ||
113 | static struct clocksource ls1x_clocksource = { | 113 | static struct clocksource ls1x_clocksource = { |
diff --git a/arch/mips/loongson64/common/cs5536/cs5536_mfgpt.c b/arch/mips/loongson64/common/cs5536/cs5536_mfgpt.c index da77d412514c..9edfa55a0e78 100644 --- a/arch/mips/loongson64/common/cs5536/cs5536_mfgpt.c +++ b/arch/mips/loongson64/common/cs5536/cs5536_mfgpt.c | |||
@@ -144,7 +144,7 @@ void __init setup_mfgpt0_timer(void) | |||
144 | * to just read by itself. So use jiffies to emulate a free | 144 | * to just read by itself. So use jiffies to emulate a free |
145 | * running counter: | 145 | * running counter: |
146 | */ | 146 | */ |
147 | static cycle_t mfgpt_read(struct clocksource *cs) | 147 | static u64 mfgpt_read(struct clocksource *cs) |
148 | { | 148 | { |
149 | unsigned long flags; | 149 | unsigned long flags; |
150 | int count; | 150 | int count; |
@@ -188,7 +188,7 @@ static cycle_t mfgpt_read(struct clocksource *cs) | |||
188 | 188 | ||
189 | raw_spin_unlock_irqrestore(&mfgpt_lock, flags); | 189 | raw_spin_unlock_irqrestore(&mfgpt_lock, flags); |
190 | 190 | ||
191 | return (cycle_t) (jifs * COMPARE) + count; | 191 | return (u64) (jifs * COMPARE) + count; |
192 | } | 192 | } |
193 | 193 | ||
194 | static struct clocksource clocksource_mfgpt = { | 194 | static struct clocksource clocksource_mfgpt = { |
diff --git a/arch/mips/loongson64/loongson-3/hpet.c b/arch/mips/loongson64/loongson-3/hpet.c index 4788bea62a6a..24afe364637b 100644 --- a/arch/mips/loongson64/loongson-3/hpet.c +++ b/arch/mips/loongson64/loongson-3/hpet.c | |||
@@ -248,9 +248,9 @@ void __init setup_hpet_timer(void) | |||
248 | pr_info("hpet clock event device register\n"); | 248 | pr_info("hpet clock event device register\n"); |
249 | } | 249 | } |
250 | 250 | ||
251 | static cycle_t hpet_read_counter(struct clocksource *cs) | 251 | static u64 hpet_read_counter(struct clocksource *cs) |
252 | { | 252 | { |
253 | return (cycle_t)hpet_read(HPET_COUNTER); | 253 | return (u64)hpet_read(HPET_COUNTER); |
254 | } | 254 | } |
255 | 255 | ||
256 | static void hpet_suspend(struct clocksource *cs) | 256 | static void hpet_suspend(struct clocksource *cs) |
diff --git a/arch/mips/mti-malta/malta-time.c b/arch/mips/mti-malta/malta-time.c index 7407da04f8d6..1829a9031eec 100644 --- a/arch/mips/mti-malta/malta-time.c +++ b/arch/mips/mti-malta/malta-time.c | |||
@@ -75,7 +75,7 @@ static void __init estimate_frequencies(void) | |||
75 | unsigned int count, start; | 75 | unsigned int count, start; |
76 | unsigned char secs1, secs2, ctrl; | 76 | unsigned char secs1, secs2, ctrl; |
77 | int secs; | 77 | int secs; |
78 | cycle_t giccount = 0, gicstart = 0; | 78 | u64 giccount = 0, gicstart = 0; |
79 | 79 | ||
80 | #if defined(CONFIG_KVM_GUEST) && CONFIG_KVM_GUEST_TIMER_FREQ | 80 | #if defined(CONFIG_KVM_GUEST) && CONFIG_KVM_GUEST_TIMER_FREQ |
81 | mips_hpt_frequency = CONFIG_KVM_GUEST_TIMER_FREQ * 1000000; | 81 | mips_hpt_frequency = CONFIG_KVM_GUEST_TIMER_FREQ * 1000000; |
diff --git a/arch/mips/netlogic/common/time.c b/arch/mips/netlogic/common/time.c index 5873c83e65be..cbbf0d48216b 100644 --- a/arch/mips/netlogic/common/time.c +++ b/arch/mips/netlogic/common/time.c | |||
@@ -59,14 +59,14 @@ unsigned int get_c0_compare_int(void) | |||
59 | return IRQ_TIMER; | 59 | return IRQ_TIMER; |
60 | } | 60 | } |
61 | 61 | ||
62 | static cycle_t nlm_get_pic_timer(struct clocksource *cs) | 62 | static u64 nlm_get_pic_timer(struct clocksource *cs) |
63 | { | 63 | { |
64 | uint64_t picbase = nlm_get_node(0)->picbase; | 64 | uint64_t picbase = nlm_get_node(0)->picbase; |
65 | 65 | ||
66 | return ~nlm_pic_read_timer(picbase, PIC_CLOCK_TIMER); | 66 | return ~nlm_pic_read_timer(picbase, PIC_CLOCK_TIMER); |
67 | } | 67 | } |
68 | 68 | ||
69 | static cycle_t nlm_get_pic_timer32(struct clocksource *cs) | 69 | static u64 nlm_get_pic_timer32(struct clocksource *cs) |
70 | { | 70 | { |
71 | uint64_t picbase = nlm_get_node(0)->picbase; | 71 | uint64_t picbase = nlm_get_node(0)->picbase; |
72 | 72 | ||
diff --git a/arch/mips/sgi-ip27/ip27-timer.c b/arch/mips/sgi-ip27/ip27-timer.c index 42d6cb9f956e..695c51bdd7dc 100644 --- a/arch/mips/sgi-ip27/ip27-timer.c +++ b/arch/mips/sgi-ip27/ip27-timer.c | |||
@@ -140,7 +140,7 @@ static void __init hub_rt_clock_event_global_init(void) | |||
140 | setup_irq(irq, &hub_rt_irqaction); | 140 | setup_irq(irq, &hub_rt_irqaction); |
141 | } | 141 | } |
142 | 142 | ||
143 | static cycle_t hub_rt_read(struct clocksource *cs) | 143 | static u64 hub_rt_read(struct clocksource *cs) |
144 | { | 144 | { |
145 | return REMOTE_HUB_L(cputonasid(0), PI_RT_COUNT); | 145 | return REMOTE_HUB_L(cputonasid(0), PI_RT_COUNT); |
146 | } | 146 | } |