Make apm buildable without legacy pm.
APM doesn't _need_ the PM_LEGACY junk, so remove it's dependancy from Kconfig, and ifdef the junk in the code.
Whilst the ifdefs are ugly, when the legacy stuff gets ripped out so will the ifdefs.
arch/i386/Kconfig renamed from arch/i386/Kconfig~ +1 -1
@@ -710,7 +710,7 @@ depends on PM && !X86_VISWS config APM tristate "APM (Advanced Power Management) BIOS support" - depends on PM && PM_LEGACY + depends on PM ---help--- APM is a BIOS specification for saving power using several different techniques. This is mostly useful for battery powered laptops with
arch/i386/kernel/apm.c renamed from arch/i386/kernel/apm.c~ +4 -0
@@ -2301,7 +2301,9 @@ static int __init apm_init(void) apm_info.disabled =1 ;return -ENODEV ; } +#ifdef CONFIG_PM_LEGACY pm_active =1 ; +#endif /* * Set up a segment that references the real mode segment 0x40
@@ -2407,7 +2409,9 @@ static void __exit apm_exit(void) exit_kapmd =1 ;while (kapmd_running)schedule (); +#ifdef CONFIG_PM_LEGACY pm_active =0 ; +#endif }module_init (apm_init);
On Tue, Jan 03, 2006 at 09:33:52AM -0500, Dave Jones took 0 lines to write:
Quoted 10 lines
APM doesn't _need_ the
PM_LEGACYjunk, so remove it's dependancy fromKconfig, and ifdef the junk in the code.
Whilst the ifdefs are ugly, when the legacy stuff gets ripped out so will the ifdefs.Signed-off-by Dave Jones <[email protected]>
arch/i386/Kconfig depends on PM && !X86_VISWS · line 716
Quoted 8 lines
arch/i386/Kconfig renamed from arch/i386/Kconfig~ +1
-1@@ -710,7 +710,7 @@ depends on PM && !X86_VISWS config APM tristate "APM (Advanced Power Management) BIOS support" - depends on PM && PM_LEGACY + depends on PM ---help--- APM is a BIOS specification for saving power using several different techniques. This is mostly useful for battery powered laptops with
Here's this hunk re-diffed against 2.6.15 (which applies without needing patch to apply an offset of -11 lines):
arch/i386/Kconfig renamed from arch/i386/Kconfig.orig +1 -1
@@ -699,7 +699,7 @@ config APM tristate "APM (Advanced Power Management) BIOS support" - depends on PM && PM_LEGACY + depends on PM ---help--- APM is a BIOS specification for saving power using several different techniques. This is mostly useful for battery powered laptops with
Kurt
Signature · 5 lines
If I traveled to the end of the rainbow As Dame Fortune did intend, Murphy would be there to tell me The pot's at the other end. -- Bert Whitney
Quoted 12 lines · Kurt Wall
On Tue, Jan 03, 2006 at 09:33:52AM -0500, Dave Jones took 0 lines to write:
Quoted 11 lines
APM doesn't _need_ the
PM_LEGACYjunk, so remove it's dependancy fromKconfig, and ifdef the junk in the code.
Whilst the ifdefs are ugly, when the legacy stuff gets ripped out so will the ifdefs.Signed-off-by Dave Jones <[email protected]>arch/i386/Kconfig renamed from arch/i386/Kconfig~ +0
-0@@ -710,7 +710,7 @@ depends on PM && !X86_VISWS
Quoted 11 lines
arch/i386/Kconfig line 705
Quoted 7 lines
arch/i386/Kconfig renamed from arch/i386/Kconfig~ +1
-1config APM tristate "APM (Advanced Power Management) BIOS support" - depends on PM && PM_LEGACY + depends on PM ---help--- APM is a BIOS specification for saving power using several different techniques. This is mostly useful for battery powered laptops withHere's this hunk re-diffed against 2.6.15 (which applies without needing patch to apply an offset of -11 lines):
...
Offsets when applying patches are usually completely harmless (problems are only possible if there isn't enough context, but that's obviously not the case here).
Quoted 1 line
Kurt
cu
Adrian
Signature · 4 lines
"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed