update for gpio PM
author沈睿汀 <srt@rock-chips.com>
Wed, 9 Jun 2010 08:30:59 +0000 (08:30 +0000)
committer黄涛 <huangtao@rock-chips.com>
Mon, 21 Jun 2010 05:35:25 +0000 (13:35 +0800)
arch/arm/mach-rk2818/gpio.c

index b225a5349c07dbc6e14dc0d473e0a1ffc7112294..b39c19e5ab289d783d8bf64549370844fb5773a1 100644 (file)
@@ -659,6 +659,8 @@ void rk2818_gpio_suspend(void)
                        wakeupsDepth[i] = 1;
                        clk_disable(rk2818gpio_chip[i].bank->clock);
                }
+               else if(wakeups[i])
+                       rk2818_gpio_write(rk2818gpio_chip[i].regbase,GPIO_INTEN,wakeups[i]);
        }
        return;
 }
@@ -923,15 +925,15 @@ static void gpio_irq_handler(unsigned irq, struct irq_desc *desc)
 
        while (isr) {
                if (isr & 1) {
-                       if (unlikely(gpio->depth)) {
+                       //if (unlikely(gpio->depth)) {
                                /*
                                 * The core ARM interrupt handler lazily disables IRQs so
                                 * another IRQ must be generated before it actually gets
                                 * here to be disabled on the GPIO controller.
                                 */
-                               gpio_irq_mask(gpioToirq);
-                       }
-                       else
+                       //      gpio_irq_mask(gpioToirq);
+                       //}
+                       //else
                        {
                                unsigned int gpio_Int_Level = 0;
                                unsigned int mask = pin_to_mask(pin);