Commit 55be6084 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'timers-core-2022-10-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip

Pull timer updates from Thomas Gleixner:
 "A boring time, timekeeping, timers update:

   - No core code changes

   - No new clocksource/event driver

   - Cleanup of the TI DM clocksource/event driver

   - The usual set of device tree binding updates

   - Small improvement, fixes and cleanups all over the place"

* tag 'timers-core-2022-10-05' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (22 commits)
  clocksource/drivers/arm_arch_timer: Fix CNTPCT_LO and CNTVCT_LO value
  clocksource/drivers/imx-sysctr: handle nxp,no-divider property
  dt-bindings: timer: nxp,sysctr-timer: add nxp,no-divider property
  clocksource/drivers/timer-ti-dm: Get clock in probe with devm_clk_get()
  clocksource/drivers/timer-ti-dm: Add flag to detect omap1
  clocksource/drivers/timer-ti-dm: Move struct omap_dm_timer fields to driver
  clocksource/drivers/timer-ti-dm: Use runtime PM directly and check errors
  clocksource/drivers/timer-ti-dm: Move private defines to the driver
  clocksource/drivers/timer-ti-dm: Simplify register access further
  clocksource/drivers/timer-ti-dm: Simplify register writes with dmtimer_write()
  clocksource/drivers/timer-ti-dm: Simplify register reads with dmtimer_read()
  clocksource/drivers/timer-ti-dm: Drop unused functions
  clocksource/drivers/timer-gxp: Add missing error handling in gxp_timer_probe
  clocksource/drivers/arm_arch_timer: Fix handling of ARM erratum 858921
  clocksource/drivers/exynos_mct: Enable building on ARTPEC
  clocksource/drivers/exynos_mct: Support local-timers property
  clocksource/drivers/exynos_mct: Support frc-shared property
  dt-bindings: timer: exynos4210-mct: Add ARTPEC-8 MCT support
  clocksource/drivers/sun4i: Add definition of clear interrupt
  clocksource/drivers/renesas-ostm: Add support for RZ/V2L SoC
  ...
parents 7f6dcffb 6cb5ce13
...@@ -25,6 +25,7 @@ Required properties: ...@@ -25,6 +25,7 @@ Required properties:
For those SoCs that use SYST For those SoCs that use SYST
* "mediatek,mt8183-timer" for MT8183 compatible timers (SYST) * "mediatek,mt8183-timer" for MT8183 compatible timers (SYST)
* "mediatek,mt8186-timer" for MT8186 compatible timers (SYST) * "mediatek,mt8186-timer" for MT8186 compatible timers (SYST)
* "mediatek,mt8188-timer" for MT8188 compatible timers (SYST)
* "mediatek,mt8192-timer" for MT8192 compatible timers (SYST) * "mediatek,mt8192-timer" for MT8192 compatible timers (SYST)
* "mediatek,mt8195-timer" for MT8195 compatible timers (SYST) * "mediatek,mt8195-timer" for MT8195 compatible timers (SYST)
* "mediatek,mt7629-timer" for MT7629 compatible timers (SYST) * "mediatek,mt7629-timer" for MT7629 compatible timers (SYST)
......
...@@ -32,6 +32,10 @@ properties: ...@@ -32,6 +32,10 @@ properties:
clock-names: clock-names:
const: per const: per
nxp,no-divider:
description: if present, means there is no internal base clk divider.
type: boolean
required: required:
- compatible - compatible
- reg - reg
......
...@@ -37,6 +37,7 @@ properties: ...@@ -37,6 +37,7 @@ properties:
- renesas,tmu-r8a77990 # R-Car E3 - renesas,tmu-r8a77990 # R-Car E3
- renesas,tmu-r8a77995 # R-Car D3 - renesas,tmu-r8a77995 # R-Car D3
- renesas,tmu-r8a779a0 # R-Car V3U - renesas,tmu-r8a779a0 # R-Car V3U
- renesas,tmu-r8a779f0 # R-Car S4-8
- const: renesas,tmu - const: renesas,tmu
reg: reg:
......
...@@ -25,6 +25,7 @@ properties: ...@@ -25,6 +25,7 @@ properties:
- samsung,exynos4412-mct - samsung,exynos4412-mct
- items: - items:
- enum: - enum:
- axis,artpec8-mct
- samsung,exynos3250-mct - samsung,exynos3250-mct
- samsung,exynos5250-mct - samsung,exynos5250-mct
- samsung,exynos5260-mct - samsung,exynos5260-mct
...@@ -45,6 +46,19 @@ properties: ...@@ -45,6 +46,19 @@ properties:
reg: reg:
maxItems: 1 maxItems: 1
samsung,frc-shared:
type: boolean
description: |
Indicates that the hardware requires that this processor share the
free-running counter with a different (main) processor.
samsung,local-timers:
$ref: /schemas/types.yaml#/definitions/uint32-array
minItems: 1
maxItems: 16
description: |
List of indices of local timers usable from this processor.
interrupts: interrupts:
description: | description: |
Interrupts should be put in specific order. This is, the local timer Interrupts should be put in specific order. This is, the local timer
...@@ -74,6 +88,17 @@ required: ...@@ -74,6 +88,17 @@ required:
- reg - reg
allOf: allOf:
- if:
not:
properties:
compatible:
contains:
enum:
- axis,artpec8-mct
then:
properties:
samsung,local-timers: false
samsung,frc-shared: false
- if: - if:
properties: properties:
compatible: compatible:
...@@ -101,6 +126,7 @@ allOf: ...@@ -101,6 +126,7 @@ allOf:
compatible: compatible:
contains: contains:
enum: enum:
- axis,artpec8-mct
- samsung,exynos5260-mct - samsung,exynos5260-mct
- samsung,exynos5420-mct - samsung,exynos5420-mct
- samsung,exynos5433-mct - samsung,exynos5433-mct
......
...@@ -434,7 +434,7 @@ config ATMEL_TCB_CLKSRC ...@@ -434,7 +434,7 @@ config ATMEL_TCB_CLKSRC
config CLKSRC_EXYNOS_MCT config CLKSRC_EXYNOS_MCT
bool "Exynos multi core timer driver" if COMPILE_TEST bool "Exynos multi core timer driver" if COMPILE_TEST
depends on ARM || ARM64 depends on ARM || ARM64
depends on ARCH_EXYNOS || COMPILE_TEST depends on ARCH_ARTPEC || ARCH_EXYNOS || COMPILE_TEST
help help
Support for Multi Core Timer controller on Exynos SoCs. Support for Multi Core Timer controller on Exynos SoCs.
......
...@@ -44,8 +44,8 @@ ...@@ -44,8 +44,8 @@
#define CNTACR_RWVT BIT(4) #define CNTACR_RWVT BIT(4)
#define CNTACR_RWPT BIT(5) #define CNTACR_RWPT BIT(5)
#define CNTVCT_LO 0x00 #define CNTPCT_LO 0x00
#define CNTPCT_LO 0x08 #define CNTVCT_LO 0x08
#define CNTFRQ 0x10 #define CNTFRQ 0x10
#define CNTP_CVAL_LO 0x20 #define CNTP_CVAL_LO 0x20
#define CNTP_CTL 0x2c #define CNTP_CTL 0x2c
...@@ -473,6 +473,8 @@ static const struct arch_timer_erratum_workaround ool_workarounds[] = { ...@@ -473,6 +473,8 @@ static const struct arch_timer_erratum_workaround ool_workarounds[] = {
.desc = "ARM erratum 858921", .desc = "ARM erratum 858921",
.read_cntpct_el0 = arm64_858921_read_cntpct_el0, .read_cntpct_el0 = arm64_858921_read_cntpct_el0,
.read_cntvct_el0 = arm64_858921_read_cntvct_el0, .read_cntvct_el0 = arm64_858921_read_cntvct_el0,
.set_next_event_phys = erratum_set_next_event_phys,
.set_next_event_virt = erratum_set_next_event_virt,
}, },
#endif #endif
#ifdef CONFIG_SUN50I_ERRATUM_UNKNOWN1 #ifdef CONFIG_SUN50I_ERRATUM_UNKNOWN1
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
#define EXYNOS4_MCT_G_INT_ENB EXYNOS4_MCTREG(0x248) #define EXYNOS4_MCT_G_INT_ENB EXYNOS4_MCTREG(0x248)
#define EXYNOS4_MCT_G_WSTAT EXYNOS4_MCTREG(0x24C) #define EXYNOS4_MCT_G_WSTAT EXYNOS4_MCTREG(0x24C)
#define _EXYNOS4_MCT_L_BASE EXYNOS4_MCTREG(0x300) #define _EXYNOS4_MCT_L_BASE EXYNOS4_MCTREG(0x300)
#define EXYNOS4_MCT_L_BASE(x) (_EXYNOS4_MCT_L_BASE + (0x100 * x)) #define EXYNOS4_MCT_L_BASE(x) (_EXYNOS4_MCT_L_BASE + (0x100 * (x)))
#define EXYNOS4_MCT_L_MASK (0xffffff00) #define EXYNOS4_MCT_L_MASK (0xffffff00)
#define MCT_L_TCNTB_OFFSET (0x00) #define MCT_L_TCNTB_OFFSET (0x00)
...@@ -66,6 +66,8 @@ ...@@ -66,6 +66,8 @@
#define MCT_L0_IRQ 4 #define MCT_L0_IRQ 4
/* Max number of IRQ as per DT binding document */ /* Max number of IRQ as per DT binding document */
#define MCT_NR_IRQS 20 #define MCT_NR_IRQS 20
/* Max number of local timers */
#define MCT_NR_LOCAL (MCT_NR_IRQS - MCT_L0_IRQ)
enum { enum {
MCT_INT_SPI, MCT_INT_SPI,
...@@ -233,8 +235,15 @@ static cycles_t exynos4_read_current_timer(void) ...@@ -233,8 +235,15 @@ static cycles_t exynos4_read_current_timer(void)
} }
#endif #endif
static int __init exynos4_clocksource_init(void) static int __init exynos4_clocksource_init(bool frc_shared)
{ {
/*
* When the frc is shared, the main processer should have already
* turned it on and we shouldn't be writing to TCON.
*/
if (frc_shared)
mct_frc.resume = NULL;
else
exynos4_mct_frc_start(); exynos4_mct_frc_start();
#if defined(CONFIG_ARM) #if defined(CONFIG_ARM)
...@@ -449,7 +458,6 @@ static int exynos4_mct_starting_cpu(unsigned int cpu) ...@@ -449,7 +458,6 @@ static int exynos4_mct_starting_cpu(unsigned int cpu)
per_cpu_ptr(&percpu_mct_tick, cpu); per_cpu_ptr(&percpu_mct_tick, cpu);
struct clock_event_device *evt = &mevt->evt; struct clock_event_device *evt = &mevt->evt;
mevt->base = EXYNOS4_MCT_L_BASE(cpu);
snprintf(mevt->name, sizeof(mevt->name), "mct_tick%d", cpu); snprintf(mevt->name, sizeof(mevt->name), "mct_tick%d", cpu);
evt->name = mevt->name; evt->name = mevt->name;
...@@ -520,8 +528,17 @@ static int __init exynos4_timer_resources(struct device_node *np) ...@@ -520,8 +528,17 @@ static int __init exynos4_timer_resources(struct device_node *np)
return 0; return 0;
} }
/**
* exynos4_timer_interrupts - initialize MCT interrupts
* @np: device node for MCT
* @int_type: interrupt type, MCT_INT_PPI or MCT_INT_SPI
* @local_idx: array mapping CPU numbers to local timer indices
* @nr_local: size of @local_idx array
*/
static int __init exynos4_timer_interrupts(struct device_node *np, static int __init exynos4_timer_interrupts(struct device_node *np,
unsigned int int_type) unsigned int int_type,
const u32 *local_idx,
size_t nr_local)
{ {
int nr_irqs, i, err, cpu; int nr_irqs, i, err, cpu;
...@@ -554,13 +571,21 @@ static int __init exynos4_timer_interrupts(struct device_node *np, ...@@ -554,13 +571,21 @@ static int __init exynos4_timer_interrupts(struct device_node *np,
} else { } else {
for_each_possible_cpu(cpu) { for_each_possible_cpu(cpu) {
int mct_irq; int mct_irq;
unsigned int irq_idx;
struct mct_clock_event_device *pcpu_mevt = struct mct_clock_event_device *pcpu_mevt =
per_cpu_ptr(&percpu_mct_tick, cpu); per_cpu_ptr(&percpu_mct_tick, cpu);
if (cpu >= nr_local) {
err = -EINVAL;
goto out_irq;
}
irq_idx = MCT_L0_IRQ + local_idx[cpu];
pcpu_mevt->evt.irq = -1; pcpu_mevt->evt.irq = -1;
if (MCT_L0_IRQ + cpu >= ARRAY_SIZE(mct_irqs)) if (irq_idx >= ARRAY_SIZE(mct_irqs))
break; break;
mct_irq = mct_irqs[MCT_L0_IRQ + cpu]; mct_irq = mct_irqs[irq_idx];
irq_set_status_flags(mct_irq, IRQ_NOAUTOEN); irq_set_status_flags(mct_irq, IRQ_NOAUTOEN);
if (request_irq(mct_irq, if (request_irq(mct_irq,
...@@ -576,6 +601,17 @@ static int __init exynos4_timer_interrupts(struct device_node *np, ...@@ -576,6 +601,17 @@ static int __init exynos4_timer_interrupts(struct device_node *np,
} }
} }
for_each_possible_cpu(cpu) {
struct mct_clock_event_device *mevt = per_cpu_ptr(&percpu_mct_tick, cpu);
if (cpu >= nr_local) {
err = -EINVAL;
goto out_irq;
}
mevt->base = EXYNOS4_MCT_L_BASE(local_idx[cpu]);
}
/* Install hotplug callbacks which configure the timer on this CPU */ /* Install hotplug callbacks which configure the timer on this CPU */
err = cpuhp_setup_state(CPUHP_AP_EXYNOS4_MCT_TIMER_STARTING, err = cpuhp_setup_state(CPUHP_AP_EXYNOS4_MCT_TIMER_STARTING,
"clockevents/exynos4/mct_timer:starting", "clockevents/exynos4/mct_timer:starting",
...@@ -605,20 +641,49 @@ static int __init exynos4_timer_interrupts(struct device_node *np, ...@@ -605,20 +641,49 @@ static int __init exynos4_timer_interrupts(struct device_node *np,
static int __init mct_init_dt(struct device_node *np, unsigned int int_type) static int __init mct_init_dt(struct device_node *np, unsigned int int_type)
{ {
bool frc_shared = of_property_read_bool(np, "samsung,frc-shared");
u32 local_idx[MCT_NR_LOCAL] = {0};
int nr_local;
int ret; int ret;
nr_local = of_property_count_u32_elems(np, "samsung,local-timers");
if (nr_local == 0)
return -EINVAL;
if (nr_local > 0) {
if (nr_local > ARRAY_SIZE(local_idx))
return -EINVAL;
ret = of_property_read_u32_array(np, "samsung,local-timers",
local_idx, nr_local);
if (ret)
return ret;
} else {
int i;
nr_local = ARRAY_SIZE(local_idx);
for (i = 0; i < nr_local; i++)
local_idx[i] = i;
}
ret = exynos4_timer_resources(np); ret = exynos4_timer_resources(np);
if (ret) if (ret)
return ret; return ret;
ret = exynos4_timer_interrupts(np, int_type); ret = exynos4_timer_interrupts(np, int_type, local_idx, nr_local);
if (ret) if (ret)
return ret; return ret;
ret = exynos4_clocksource_init(); ret = exynos4_clocksource_init(frc_shared);
if (ret) if (ret)
return ret; return ret;
/*
* When the FRC is shared with a main processor, this secondary
* processor cannot use the global comparator.
*/
if (frc_shared)
return ret;
return exynos4_clockevent_init(); return exynos4_clockevent_init();
} }
......
...@@ -224,7 +224,7 @@ static int __init ostm_init(struct device_node *np) ...@@ -224,7 +224,7 @@ static int __init ostm_init(struct device_node *np)
TIMER_OF_DECLARE(ostm, "renesas,ostm", ostm_init); TIMER_OF_DECLARE(ostm, "renesas,ostm", ostm_init);
#ifdef CONFIG_ARCH_R9A07G044 #ifdef CONFIG_ARCH_RZG2L
static int __init ostm_probe(struct platform_device *pdev) static int __init ostm_probe(struct platform_device *pdev)
{ {
struct device *dev = &pdev->dev; struct device *dev = &pdev->dev;
......
...@@ -171,6 +171,7 @@ static int gxp_timer_probe(struct platform_device *pdev) ...@@ -171,6 +171,7 @@ static int gxp_timer_probe(struct platform_device *pdev)
{ {
struct platform_device *gxp_watchdog_device; struct platform_device *gxp_watchdog_device;
struct device *dev = &pdev->dev; struct device *dev = &pdev->dev;
int ret;
if (!gxp_timer) { if (!gxp_timer) {
pr_err("Gxp Timer not initialized, cannot create watchdog"); pr_err("Gxp Timer not initialized, cannot create watchdog");
...@@ -187,7 +188,11 @@ static int gxp_timer_probe(struct platform_device *pdev) ...@@ -187,7 +188,11 @@ static int gxp_timer_probe(struct platform_device *pdev)
gxp_watchdog_device->dev.platform_data = gxp_timer->counter; gxp_watchdog_device->dev.platform_data = gxp_timer->counter;
gxp_watchdog_device->dev.parent = dev; gxp_watchdog_device->dev.parent = dev;
return platform_device_add(gxp_watchdog_device); ret = platform_device_add(gxp_watchdog_device);
if (ret)
platform_device_put(gxp_watchdog_device);
return ret;
} }
static const struct of_device_id gxp_timer_of_match[] = { static const struct of_device_id gxp_timer_of_match[] = {
......
...@@ -134,8 +134,10 @@ static int __init sysctr_timer_init(struct device_node *np) ...@@ -134,8 +134,10 @@ static int __init sysctr_timer_init(struct device_node *np)
if (ret) if (ret)
return ret; return ret;
if (!of_property_read_bool(np, "nxp,no-divider")) {
/* system counter clock is divided by 3 internally */ /* system counter clock is divided by 3 internally */
to_sysctr.of_clk.rate /= SYS_CTR_CLK_DIV; to_sysctr.of_clk.rate /= SYS_CTR_CLK_DIV;
}
sys_ctr_base = timer_of_base(&to_sysctr); sys_ctr_base = timer_of_base(&to_sysctr);
cmpcr = readl(sys_ctr_base + CMPCR); cmpcr = readl(sys_ctr_base + CMPCR);
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
#define TIMER_IRQ_EN_REG 0x00 #define TIMER_IRQ_EN_REG 0x00
#define TIMER_IRQ_EN(val) BIT(val) #define TIMER_IRQ_EN(val) BIT(val)
#define TIMER_IRQ_ST_REG 0x04 #define TIMER_IRQ_ST_REG 0x04
#define TIMER_IRQ_CLEAR(val) BIT(val)
#define TIMER_CTL_REG(val) (0x10 * val + 0x10) #define TIMER_CTL_REG(val) (0x10 * val + 0x10)
#define TIMER_CTL_ENABLE BIT(0) #define TIMER_CTL_ENABLE BIT(0)
#define TIMER_CTL_RELOAD BIT(1) #define TIMER_CTL_RELOAD BIT(1)
...@@ -123,7 +124,7 @@ static int sun4i_clkevt_next_event(unsigned long evt, ...@@ -123,7 +124,7 @@ static int sun4i_clkevt_next_event(unsigned long evt,
static void sun4i_timer_clear_interrupt(void __iomem *base) static void sun4i_timer_clear_interrupt(void __iomem *base)
{ {
writel(TIMER_IRQ_EN(0), base + TIMER_IRQ_ST_REG); writel(TIMER_IRQ_CLEAR(0), base + TIMER_IRQ_ST_REG);
} }
static irqreturn_t sun4i_timer_interrupt(int irq, void *dev_id) static irqreturn_t sun4i_timer_interrupt(int irq, void *dev_id)
......
This diff is collapsed.
...@@ -52,10 +52,6 @@ ...@@ -52,10 +52,6 @@
#define OMAP_TIMER_TRIGGER_OVERFLOW 0x01 #define OMAP_TIMER_TRIGGER_OVERFLOW 0x01
#define OMAP_TIMER_TRIGGER_OVERFLOW_AND_COMPARE 0x02 #define OMAP_TIMER_TRIGGER_OVERFLOW_AND_COMPARE 0x02
/* posted mode types */
#define OMAP_TIMER_NONPOSTED 0x00
#define OMAP_TIMER_POSTED 0x01
/* timer capabilities used in hwmod database */ /* timer capabilities used in hwmod database */
#define OMAP_TIMER_SECURE 0x80000000 #define OMAP_TIMER_SECURE 0x80000000
#define OMAP_TIMER_ALWON 0x40000000 #define OMAP_TIMER_ALWON 0x40000000
...@@ -63,73 +59,13 @@ ...@@ -63,73 +59,13 @@
#define OMAP_TIMER_NEEDS_RESET 0x10000000 #define OMAP_TIMER_NEEDS_RESET 0x10000000
#define OMAP_TIMER_HAS_DSP_IRQ 0x08000000 #define OMAP_TIMER_HAS_DSP_IRQ 0x08000000
/*
* timer errata flags
*
* Errata i103/i767 impacts all OMAP3/4/5 devices including AM33xx. This
* errata prevents us from using posted mode on these devices, unless the
* timer counter register is never read. For more details please refer to
* the OMAP3/4/5 errata documents.
*/
#define OMAP_TIMER_ERRATA_I103_I767 0x80000000
struct timer_regs {
u32 ocp_cfg;
u32 tidr;
u32 tier;
u32 twer;
u32 tclr;
u32 tcrr;
u32 tldr;
u32 ttrg;
u32 twps;
u32 tmar;
u32 tcar1;
u32 tsicr;
u32 tcar2;
u32 tpir;
u32 tnir;
u32 tcvr;
u32 tocr;
u32 towr;
};
struct omap_dm_timer { struct omap_dm_timer {
int id;
int irq;
struct clk *fclk;
void __iomem *io_base;
void __iomem *irq_stat; /* TISR/IRQSTATUS interrupt status */
void __iomem *irq_ena; /* irq enable */
void __iomem *irq_dis; /* irq disable, only on v2 ip */
void __iomem *pend; /* write pending */
void __iomem *func_base; /* function register base */
atomic_t enabled;
unsigned long rate;
unsigned reserved:1;
unsigned posted:1;
struct timer_regs context;
int revision;
u32 capability;
u32 errata;
struct platform_device *pdev;
struct list_head node;
struct notifier_block nb;
}; };
int omap_dm_timer_reserve_systimer(int id);
struct omap_dm_timer *omap_dm_timer_request_by_cap(u32 cap);
int omap_dm_timer_get_irq(struct omap_dm_timer *timer); int omap_dm_timer_get_irq(struct omap_dm_timer *timer);
u32 omap_dm_timer_modify_idlect_mask(u32 inputmask); u32 omap_dm_timer_modify_idlect_mask(u32 inputmask);
int omap_dm_timer_trigger(struct omap_dm_timer *timer);
int omap_dm_timers_active(void);
/* /*
* Do not use the defines below, they are not needed. They should be only * Do not use the defines below, they are not needed. They should be only
* used by dmtimer.c and sys_timer related code. * used by dmtimer.c and sys_timer related code.
...@@ -199,52 +135,4 @@ int omap_dm_timers_active(void); ...@@ -199,52 +135,4 @@ int omap_dm_timers_active(void);
#define _OMAP_TIMER_TICK_INT_MASK_SET_OFFSET 0x54 /* TOCR, 34xx only */ #define _OMAP_TIMER_TICK_INT_MASK_SET_OFFSET 0x54 /* TOCR, 34xx only */
#define _OMAP_TIMER_TICK_INT_MASK_COUNT_OFFSET 0x58 /* TOWR, 34xx only */ #define _OMAP_TIMER_TICK_INT_MASK_COUNT_OFFSET 0x58 /* TOWR, 34xx only */
/* register offsets with the write pending bit encoded */
#define WPSHIFT 16
#define OMAP_TIMER_WAKEUP_EN_REG (_OMAP_TIMER_WAKEUP_EN_OFFSET \
| (WP_NONE << WPSHIFT))
#define OMAP_TIMER_CTRL_REG (_OMAP_TIMER_CTRL_OFFSET \
| (WP_TCLR << WPSHIFT))
#define OMAP_TIMER_COUNTER_REG (_OMAP_TIMER_COUNTER_OFFSET \
| (WP_TCRR << WPSHIFT))
#define OMAP_TIMER_LOAD_REG (_OMAP_TIMER_LOAD_OFFSET \
| (WP_TLDR << WPSHIFT))
#define OMAP_TIMER_TRIGGER_REG (_OMAP_TIMER_TRIGGER_OFFSET \
| (WP_TTGR << WPSHIFT))
#define OMAP_TIMER_WRITE_PEND_REG (_OMAP_TIMER_WRITE_PEND_OFFSET \
| (WP_NONE << WPSHIFT))
#define OMAP_TIMER_MATCH_REG (_OMAP_TIMER_MATCH_OFFSET \
| (WP_TMAR << WPSHIFT))
#define OMAP_TIMER_CAPTURE_REG (_OMAP_TIMER_CAPTURE_OFFSET \
| (WP_NONE << WPSHIFT))
#define OMAP_TIMER_IF_CTRL_REG (_OMAP_TIMER_IF_CTRL_OFFSET \
| (WP_NONE << WPSHIFT))
#define OMAP_TIMER_CAPTURE2_REG (_OMAP_TIMER_CAPTURE2_OFFSET \
| (WP_NONE << WPSHIFT))
#define OMAP_TIMER_TICK_POS_REG (_OMAP_TIMER_TICK_POS_OFFSET \
| (WP_TPIR << WPSHIFT))
#define OMAP_TIMER_TICK_NEG_REG (_OMAP_TIMER_TICK_NEG_OFFSET \
| (WP_TNIR << WPSHIFT))
#define OMAP_TIMER_TICK_COUNT_REG (_OMAP_TIMER_TICK_COUNT_OFFSET \
| (WP_TCVR << WPSHIFT))
#define OMAP_TIMER_TICK_INT_MASK_SET_REG \
(_OMAP_TIMER_TICK_INT_MASK_SET_OFFSET | (WP_TOCR << WPSHIFT))
#define OMAP_TIMER_TICK_INT_MASK_COUNT_REG \
(_OMAP_TIMER_TICK_INT_MASK_COUNT_OFFSET | (WP_TOWR << WPSHIFT))
#endif /* __CLOCKSOURCE_DMTIMER_H */ #endif /* __CLOCKSOURCE_DMTIMER_H */
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment