From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754442AbZFLRKP (ORCPT ); Fri, 12 Jun 2009 13:10:15 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1751177AbZFLRKE (ORCPT ); Fri, 12 Jun 2009 13:10:04 -0400 Received: from www.tglx.de ([62.245.132.106]:42103 "EHLO www.tglx.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751100AbZFLRKD (ORCPT ); Fri, 12 Jun 2009 13:10:03 -0400 Date: Fri, 12 Jun 2009 19:09:34 +0200 (CEST) From: Thomas Gleixner To: LKML cc: "Rafael J. Wysocki" , Russell King , Ingo Molnar Subject: [PATCH] genirq: do not disable IRQ_WAKEUP marked irqs on suspend Message-ID: User-Agent: Alpine 2.00 (LFD 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org commit 0a0c5168df (PM: Introduce functions for suspending and resuming device interrupts) iterates through all interrupts and disables them on the hardware level. Some architectures have functionality implemented to mark an interrupt source as wakeup source for suspend, but the new power management code disables them unconditionally which breaks the resume on interrupt functionality. The wakeup interrupts are marked in the status with the IRQ_WAKEUP bit. Skip the disablement for those interrupts which have the IRQ_WAKEUP bit set. Signed-off-by: Thomas Gleixner Cc: stable@kernel.org diff --git a/kernel/irq/pm.c b/kernel/irq/pm.c index 638d8be..bce6afd 100644 --- a/kernel/irq/pm.c +++ b/kernel/irq/pm.c @@ -29,7 +29,8 @@ void suspend_device_irqs(void) unsigned long flags; spin_lock_irqsave(&desc->lock, flags); - __disable_irq(desc, irq, true); + if (!(desc->status & IRQ_WAKEUP)) + __disable_irq(desc, irq, true); spin_unlock_irqrestore(&desc->lock, flags); }