Hi All,
My customer want to use AM3703 GPIO_116 for getting interrupt from RTC present in TPS65951 chip. He use kernel 3.0.3 from kernel.org.
The RTC interrupt line is directly connected to GPIO_116.
Enabled GPIO with pin mux
OMAP3_MUX(MCBSP2_FSX, OMAP_MUX_MODE4 | OMAP_PIN_INPUT), /*GPIO 116 : PS_INT*/
static struct twl4030_platform_data beagle_twldata = {
.irq_base = TWL4030_IRQ_BASE,
.irq_end = TWL4030_IRQ_END,
};
static struct i2c_board_info __initdata beagle_i2c_boardinfo[] = {
{
I2C_BOARD_INFO("twl4030", 0x48),
.flags = I2C_CLIENT_WAKE,
.irq = gpio_to_irq(116),
.platform_data = &beagle_twldata,
},
};
static int __init omap3_beagle_i2c_init(void)
{
omap_register_i2c_bus(1, 2600, beagle_i2c_boardinfo,
ARRAY_SIZE(beagle_i2c_boardinfo));
return 0;
}
On beagle with .irq= INT_34XX_SYS_NIRQ enabled:
======================================
root@omap:/boot/uboot# cat /proc/interrupts
7: 0 INTC TWL4030-PIH
379: 0 twl4030 rtc0
He ran rtc test program, interrupts got updated:
root@omap:/boot/uboot# cat /proc/interrupts
7: 1 INTC TWL4030-PIH
379: 1 twl4030 rtc0
On our customized design with .irq= gpio_to_irq(116) :
=======================================
root@omap:/boot/uboot# cat /proc/interrupts
276: 0 gpio TWL4030-PIH
379: 0 twl4030 rtc0
He ran rtc test program, didn’t see the interrupts are getting updated:
root@omap:/boot/uboot# cat /proc/interrupts
276: 0 gpio TWL4030-PIH
379: 0 twl4030 rtc0
Finally "hwclock" command should read RTC value without fail.
Are the settings done properly, do we need to take care of anything else. Please advice.
Thanks!!
Regards
Sathish