Skip to content

Commit

Permalink
powerpc/pmac: Don't register pmac PIC syscore ops when HW not present
Browse files Browse the repository at this point in the history
The Apple custom PIC only exist in some earlier machine models,
anything with an MPIC will crash on suspend if we register those
syscore ops unconditionally.

This is a regression caused by commit f5a592f ("PM / PowerPC: Use
struct syscore_ops instead of sysdevs for PM")

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Benjamin Herrenschmidt authored and Linus Torvalds committed May 31, 2011
1 parent 55922c9 commit 339dedf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/powerpc/platforms/powermac/pic.c
Original file line number Diff line number Diff line change
Expand Up @@ -715,7 +715,8 @@ static struct syscore_ops pmacpic_syscore_ops = {

static int __init init_pmacpic_syscore(void)
{
register_syscore_ops(&pmacpic_syscore_ops);
if (pmac_irq_hw[0])
register_syscore_ops(&pmacpic_syscore_ops);
return 0;
}

Expand Down

0 comments on commit 339dedf

Please sign in to comment.