Skip to content

Commit

Permalink
[ARM] 4088/1: AT91: Unbalanced IRQ in serial driver suspend/resume
Browse files Browse the repository at this point in the history
This patch fixes the unbalanced calls to enable_irq_wake() and
disable_irq_wake() in the AT91 (and AVR32) serial driver.

It should resolve these kernel messages:
  Unbalanced IRQ x wake disable
  BUG: warning at kernel/irq/manage.c:167/set_irq_wake()

Original patch from Marc Pignat.

Signed-off-by: Andrew Victor <andrew@sanpeople.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Andrew Victor authored and Russell King committed Jan 24, 2007
1 parent e9d10a1 commit 9b93816
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/serial/atmel_serial.c
Original file line number Diff line number Diff line change
Expand Up @@ -890,7 +890,6 @@ static int atmel_serial_suspend(struct platform_device *pdev, pm_message_t state
if (device_may_wakeup(&pdev->dev) && !at91_suspend_entering_slow_clock())
enable_irq_wake(port->irq);
else {
disable_irq_wake(port->irq);
uart_suspend_port(&atmel_uart, port);
atmel_port->suspended = 1;
}
Expand All @@ -907,6 +906,8 @@ static int atmel_serial_resume(struct platform_device *pdev)
uart_resume_port(&atmel_uart, port);
atmel_port->suspended = 0;
}
else
disable_irq_wake(port->irq);

return 0;
}
Expand Down

0 comments on commit 9b93816

Please sign in to comment.