Skip to content

Commit

Permalink
[ARM] 3342/1: NSLU2: Protect power button init routine with machine_i…
Browse files Browse the repository at this point in the history
…s_nslu2()

Patch from Alessandro Zummo

The power button exit routine for the Linksys NSLU2 was not protected by
a machine_is_nslu2(). This patch fixes it.

Signed-off-by: Rod Whitby <rod@whitby.id.au>
Signed-off-by: Alessandro Zummo <a.zummo@towertech.it>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Alessandro Zummo authored and Russell King committed Feb 22, 2006
1 parent c27a216 commit d7353b2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions arch/arm/mach-ixp4xx/nslu2-power.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ static int __init nslu2_power_init(void)

static void __exit nslu2_power_exit(void)
{
if (!(machine_is_nslu2()))
return;

free_irq(NSLU2_RB_IRQ, NULL);
free_irq(NSLU2_PB_IRQ, NULL);
}
Expand Down

0 comments on commit d7353b2

Please sign in to comment.