[OpenWrt-Devel] brcm63xx: Question about external IRQs
dani
dgcbueu at gmail.com
Sat Dec 19 13:13:07 EST 2015
I have no idea if external IRQs are currenlty used for any purpose in bcm63xx,
buy they seem to be broken.
Some GPIOs in bcm63xx are shared with those external IRQs. Usually those GPIOs
in bcm63xx are wired to some buttons, but not all.
Since I know the matching between external IRQs and GPIOs, I used this code
for checking if the external IRQs really work, just by pressing the button.
/***************************************************/
static irqreturn_t gpio_interrupt(int irq, void *dev_id)
{
printk("my IRQ triggered!!!!\n");
return IRQ_HANDLED;
}
int bcm63xx_button_init(void)
{
int ret, irq;
printk("TEST IRQ (GPIO-button)\n");
irq = IRQ_EXT_1;
ret = request_irq(irq, gpio_interrupt, 0, "bcm63xx_extIRQ", NULL);
if (ret) {
printk(KERN_ERR "bcm63xx-extIRQ: failed to register irq %d\n",irq);
return ret;
}
printk("Mapped IRQ %d\n", irq );
return 0;
}
arch_initcall(bcm63xx_button_init);
/***************************************************/
in the kernel code at setup.c.
In Attitude adjustment, it worked printing messages on the console:
my IRQ triggered!!!!
my IRQ triggered!!!!
every time I press the button connected to GPIO35 in a BCM6368 board. It also worked with
BCM6348.
But with latest trunk, or Chaos Calmer nothing happens spite of using exactly the same snippet
code, and the kernel doesn't complain about anything related to IRQs. This time I only checked it
in BCM6368 (the same board I previously used with AA).
Are external IRQs broken?, did anyone check if they work?
I also noticed bcm63xx_irq.h has defined only 4 external IRQs, but some SoCs like BCM6368 or BCM63168
have 6.
Regards.
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list