提交 2f344d2e 编写于 作者: S Suresh Siddha 提交者: Ingo Molnar

x86, ioapic: Restore ioapic entries during resume properly

In mask/restore_ioapic_entries() we should be restoring ioapic
entries when ioapics[apic].saved_registers is not NULL.

Fix the typo and address the resume hang regression reported by
Linus.

This was not found sooner because the systems where these
changes were tested on kept the IO-APIC entries intact over
resume.
Reported-and-tested-by: NLinus Torvalds <torvalds@linux-foundation.org>
Signed-off-by: NSuresh Siddha <suresh.b.siddha@intel.com>
Cc: Daniel J Blueman <daniel.blueman@gmail.com>
Link: http://lkml.kernel.org/r/1306259131.7171.7.camel@sbsiddha-MOBL3.sc.intel.comSigned-off-by: NIngo Molnar <mingo@elte.hu>
上级 1b4ac2a9
......@@ -676,7 +676,7 @@ void mask_ioapic_entries(void)
int apic, pin;
for (apic = 0; apic < nr_ioapics; apic++) {
if (ioapics[apic].saved_registers)
if (!ioapics[apic].saved_registers)
continue;
for (pin = 0; pin < ioapics[apic].nr_registers; pin++) {
......@@ -699,7 +699,7 @@ int restore_ioapic_entries(void)
int apic, pin;
for (apic = 0; apic < nr_ioapics; apic++) {
if (ioapics[apic].saved_registers)
if (!ioapics[apic].saved_registers)
continue;
for (pin = 0; pin < ioapics[apic].nr_registers; pin++)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册