]> git.neil.brown.name Git - history.git/commitdiff
Cset exclude: len.brown@intel.com[lenb]|ChangeSet|20041109085620|42985
authorLen Brown <len.brown@intel.com>
Wed, 1 Dec 2004 07:40:31 +0000 (02:40 -0500)
committerLen Brown <lenb@dhcppc3.>
Wed, 1 Dec 2004 07:40:31 +0000 (02:40 -0500)
arch/i386/kernel/apic.c

index 1bf09be85d39d7de7b0433d2666089cd0b654329..64c175ff4a9228c1cd68564ad335eaf55e0f61ec 100644 (file)
@@ -514,23 +514,9 @@ static struct {
        unsigned int apic_thmr;
 } apic_pm_state;
 
-static int lapic_shutdown(struct sys_device *dev)
-{
-       unsigned long flags;
-
-       if (!apic_pm_state.active)
-               return 0;
-
-       
-       local_irq_save(flags);
-       disable_local_APIC();
-       local_irq_restore(flags);
-       
-       return 0;
-}
-
 static int lapic_suspend(struct sys_device *dev, u32 state)
 {
+       unsigned long flags;
 
        if (!apic_pm_state.active)
                return 0;
@@ -549,7 +535,10 @@ static int lapic_suspend(struct sys_device *dev, u32 state)
        apic_pm_state.apic_tdcr = apic_read(APIC_TDCR);
        apic_pm_state.apic_thmr = apic_read(APIC_LVTTHMR);
        
-       return lapic_shutdown(dev);
+       local_irq_save(flags);
+       disable_local_APIC();
+       local_irq_restore(flags);
+       return 0;
 }
 
 static int lapic_resume(struct sys_device *dev)
@@ -598,7 +587,6 @@ static int lapic_resume(struct sys_device *dev)
 
 static struct sysdev_class lapic_sysclass = {
        set_kset_name("lapic"),
-       .shutdown       = lapic_shutdown,
        .resume         = lapic_resume,
        .suspend        = lapic_suspend,
 };