Tool/software: Linux
We have an AM335x system based on Linux kernel 3.2 and the system is not able to wake up from standby via a GPIO (gpio0_7) toggle. However, UART1 activity is able to wake up the system from standby.
The code is based on TI Arago tree kernel update from: git://arago-project.org/git/projects/linux-am33x.git
v3.2-staging, commit 4be2ce1b85bcec765a05f30 (~05/2013).
A large number of patches have also been applied since then, tracking long term stable kernels, our own bug fixes, security patches and added features.
Here are the steps we use to go into standby mode:
echo 1 > /debugfs/omap_mux/board/suspend_io_pad_conf/enable_suspend_io_pad_conf
echo gpio0_7=0x37,falling > /debugfs/omap_mux/board/standby_gpio_pad_conf
or
echo gpio0_7=0x27,rising > /debugfs/omap_mux/board/standby_gpio_pad_conf
echo 0 > /sys/class/rtc/rtc0/wakealarm
echo standby > /sys/power/state
We debugged into the kernel sources to confirm that the gpio0_7 setup as IRQ 167 source in am33xx_standby_setup of mux33xx.c
What we have tried :
1) {"gpio0_7", OMAP_MUX_MODE7 | AM33XX_PIN_INPUT_PULLUP}
2) {"gpio0_7", OMAP_MUX_MODE7 | AM33XX_PIN_INPUT_PULLUP | OMAP_WAKEUP_EN}
3) setup gpio pad
static struct omap_device_pad default_gpio0_7_pad[] __initdata = {
{
.name = "ecap0_in_pwm0_out.gpio0_7",
.flags = OMAP_DEVICE_PAD_REMUX | OMAP_DEVICE_PAD_WAKEUP,
.enable = OMAP_PIN_INPUT_PULLUP | OMAP_MUX_MODE7,
.idle = OMAP_PIN_INPUT_PULLUP | OMAP_MUX_MODE7,
},
};
4) force to Wakeup domain GPIO by
gpio1_oh = omap_hwmod_lookup("gpio1"); /* WKUP domain GPIO */
omap_hwmod_enable_wakeup(gpio1_oh);
None of these work and GPIO0_7 cannot trigger any event.
Please let us know of any additional suggestions or tests to try.