From b20384ef35b95172e9680a0ae6cb7430fd9d6d1f Mon Sep 17 00:00:00 2001 From: Russell King Date: Tue, 13 Sep 2016 14:50:10 +0100 Subject: ARM: sa1100/simpad: use gpio-keys to enable wakeup on power button Enable wakeup for the power button via gpio-keys, rather than relying on setting PWER directly. Signed-off-by: Russell King --- arch/arm/mach-sa1100/simpad.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/arch/arm/mach-sa1100/simpad.c b/arch/arm/mach-sa1100/simpad.c index db46668cdad5..ae7512a025e8 100644 --- a/arch/arm/mach-sa1100/simpad.c +++ b/arch/arm/mach-sa1100/simpad.c @@ -220,13 +220,9 @@ static void __init simpad_map_io(void) /* * Set up registers for sleep mode. */ - - - PWER = PWER_GPIO0| PWER_RTC; PGSR = 0x818; PCFR = 0; PSDR = 0; - } static void simpad_power_off(void) @@ -237,8 +233,7 @@ static void simpad_power_off(void) /* disable internal oscillator, float CS lines */ PCFR = (PCFR_OPDE | PCFR_FP | PCFR_FS); - /* enable wake-up on GPIO0 */ - PWER = GFER = GRER = PWER_GPIO0; + /* * set scratchpad to zero, just in case it is used as a * restart address by the bootloader. @@ -264,6 +259,7 @@ static struct gpio_keys_button simpad_button_table[] = { .gpio = GPIO_POWER_BUTTON, .active_low = 1, .desc = "power button", + .wakeup = 1, }, }; -- cgit