serenity icon indicating copy to clipboard operation
serenity copied to clipboard

Kernel: Implement ACPI-based shutdown

Open IdanHo opened this issue 1 year ago • 2 comments

This includes a couple of bug-fixes, and the pretty big pre-requisite of an AML parser, but we can finally shutdown some* baremetal PCs :^)

* Those that don't require AML execution, which is not part of this PR.

IdanHo avatar Jun 22 '23 11:06 IdanHo

Nice! I wonder how easily we could abstract the AML interpreter so we can run unit tests? It feels like we could abstract all kernel/io interactions into an interface maybe?

tomuta avatar Jun 22 '23 16:06 tomuta

@tomuta Sure, that interface is pretty strictly defined by the specification anyways, so we could probably have 2 implementations, one for the kernel, and a mock one for testing. (Note though that this PR does not implement an AML interpreter we only parse it, thankfully execution is not actually required for implementing shutdown in a lot of cases, so the next step of executing it is left as a TODO for a future PR)

IdanHo avatar Jun 22 '23 16:06 IdanHo

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions!

stale[bot] avatar Aug 05 '23 16:08 stale[bot]

This pull request has been closed because it has not had recent activity. Feel free to re-open if you wish to still contribute these changes. Thank you for your contributions!

stale[bot] avatar Aug 12 '23 18:08 stale[bot]