Skip to content

Commit d4c5c46

Browse files
havmindgregkh
authored andcommitted
drivers/clocksource: timer-fsl-ftm: use common header for FlexTimer #defines
Common #defines have been moved to "linux/fsl/ftm.h". Thus making use of this file. Also FTM_SC_CLK_SHIFT has been renamed to FTM_SC_CLK_MASK_SHIFT. Reviewed-by: Esben Haabendal <[email protected]> Signed-off-by: Patrick Havelange <[email protected]> Signed-off-by: William Breathitt Gray <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent e590eb4 commit d4c5c46

File tree

1 file changed

+2
-13
lines changed

1 file changed

+2
-13
lines changed

drivers/clocksource/timer-fsl-ftm.c

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,9 @@
1919
#include <linux/of_irq.h>
2020
#include <linux/sched_clock.h>
2121
#include <linux/slab.h>
22+
#include <linux/fsl/ftm.h>
2223

23-
#define FTM_SC 0x00
24-
#define FTM_SC_CLK_SHIFT 3
25-
#define FTM_SC_CLK_MASK (0x3 << FTM_SC_CLK_SHIFT)
26-
#define FTM_SC_CLK(c) ((c) << FTM_SC_CLK_SHIFT)
27-
#define FTM_SC_PS_MASK 0x7
28-
#define FTM_SC_TOIE BIT(6)
29-
#define FTM_SC_TOF BIT(7)
30-
31-
#define FTM_CNT 0x04
32-
#define FTM_MOD 0x08
33-
#define FTM_CNTIN 0x4C
34-
35-
#define FTM_PS_MAX 7
24+
#define FTM_SC_CLK(c) ((c) << FTM_SC_CLK_MASK_SHIFT)
3625

3726
struct ftm_clock_device {
3827
void __iomem *clksrc_base;

0 commit comments

Comments
 (0)