On Fri, 7 Jul 2023 11:56:42 +0200 Tobias Heider <tobias.hei...@stusta.de> wrote: > On Wed, Jul 05, 2023 at 04:53:33PM +0200, Tobias Heider wrote: >> I am planning to restructure the APM/sleep APIs to make it easier to suspend >> from more places like as a suspend keyboard shortcut. >> >> The acpiioctl handler is x86 specific code which is currently built on all >> platforms but only hooked up on i386 and amd64. It is also in the way of >> my plans, so I'd prefer if we move it to acpi_x86.c where all the other >> x86-only acpi code lives. >> > > The previous diff wasn't enough to solve the problem and broke RAMDISK, > so here's a next try. This moves anything /dev/apm related to the > new acpi_apm.c file which is only included on i386 and amd64 and properly > handles SMALL_KERNEL. > > Some apm related code (apm_apminfo, acpi_sleep_task) remains in acpi.c for > now because it is also used by arm64 or called from MI paths. > I plan to clean up the sleep task in the follow-up diff but this one is > big enough already. > > Tested on amd64, i386, macppc and arm64 with GENERIC.MP and RAMDISK.
Tested on my vaio. No regression so far. Also the diff seems correct.