diff options
author | Jim Cromie <jim.cromie@gmail.com> | 2006-06-26 03:25:15 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2006-06-26 12:58:21 -0400 |
commit | 7f9f303aa33c7acc7b4aa9ebea25cbd990bc707b (patch) | |
tree | b5916e6b018356afdb5c8687e554a049532633bd /drivers/clocksource/cyclone.c | |
parent | 7d622d4794490cef933c20e4a6279e43e03fafad (diff) |
[PATCH] generic-time: add macro to simplify/hide mask constants
Add a CLOCKSOURCE_MASK macro to simplify initializing the mask for a struct
clocksource, and use it to replace literal mask constants in the various
clocksource drivers.
Signed-off-by: Jim Cromie <jim.cromie@gmail.com>
Acked-by: John Stultz <johnstul@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/clocksource/cyclone.c')
-rw-r--r-- | drivers/clocksource/cyclone.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/clocksource/cyclone.c b/drivers/clocksource/cyclone.c index 5906a0af825d..bf4d3d50d1c4 100644 --- a/drivers/clocksource/cyclone.c +++ b/drivers/clocksource/cyclone.c | |||
@@ -14,7 +14,7 @@ | |||
14 | #define CYCLONE_MPCS_OFFSET 0x51A8 /* offset to select register */ | 14 | #define CYCLONE_MPCS_OFFSET 0x51A8 /* offset to select register */ |
15 | #define CYCLONE_MPMC_OFFSET 0x51D0 /* offset to count register */ | 15 | #define CYCLONE_MPMC_OFFSET 0x51D0 /* offset to count register */ |
16 | #define CYCLONE_TIMER_FREQ 99780000 /* 100Mhz, but not really */ | 16 | #define CYCLONE_TIMER_FREQ 99780000 /* 100Mhz, but not really */ |
17 | #define CYCLONE_TIMER_MASK 0xFFFFFFFF /* 32 bit mask */ | 17 | #define CYCLONE_TIMER_MASK CLOCKSOURCE_MASK(32) /* 32 bit mask */ |
18 | 18 | ||
19 | int use_cyclone = 0; | 19 | int use_cyclone = 0; |
20 | static void __iomem *cyclone_ptr; | 20 | static void __iomem *cyclone_ptr; |
@@ -28,7 +28,7 @@ static struct clocksource clocksource_cyclone = { | |||
28 | .name = "cyclone", | 28 | .name = "cyclone", |
29 | .rating = 250, | 29 | .rating = 250, |
30 | .read = read_cyclone, | 30 | .read = read_cyclone, |
31 | .mask = (cycle_t)CYCLONE_TIMER_MASK, | 31 | .mask = CYCLONE_TIMER_MASK, |
32 | .mult = 10, | 32 | .mult = 10, |
33 | .shift = 0, | 33 | .shift = 0, |
34 | .is_continuous = 1, | 34 | .is_continuous = 1, |