Lines Matching refs:id
57 int bcm63xx_timer_enable(int id)
62 if (id >= BCM63XX_TIMER_COUNT)
67 reg = bcm_timer_readl(TIMER_CTLx_REG(id));
69 bcm_timer_writel(reg, TIMER_CTLx_REG(id));
72 reg |= TIMER_IRQSTAT_TIMER_IR_EN(id);
81 int bcm63xx_timer_disable(int id)
86 if (id >= BCM63XX_TIMER_COUNT)
91 reg = bcm_timer_readl(TIMER_CTLx_REG(id));
93 bcm_timer_writel(reg, TIMER_CTLx_REG(id));
96 reg &= ~TIMER_IRQSTAT_TIMER_IR_EN(id);
105 int bcm63xx_timer_register(int id, void (*callback)(void *data), void *data)
110 if (id >= BCM63XX_TIMER_COUNT || !callback)
115 if (timer_data[id].cb) {
120 timer_data[id].cb = callback;
121 timer_data[id].data = data;
130 void bcm63xx_timer_unregister(int id)
134 if (id >= BCM63XX_TIMER_COUNT)
138 timer_data[id].cb = NULL;
151 int bcm63xx_timer_set(int id, int monotonic, unsigned int countdown_us)
156 if (id >= BCM63XX_TIMER_COUNT)
164 reg = bcm_timer_readl(TIMER_CTLx_REG(id));
173 bcm_timer_writel(reg, TIMER_CTLx_REG(id));