1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 12:27:34 +00:00

Kernel: Don't use references or pointers to physical addresses

Now the ACPI & PCI code is more safer, because we don't use raw pointers
or references to objects or data that are located in the physical
address space, so an accidental dereference cannot happen easily.
Instead, we use the PhysicalAddress class to represent those addresses.
This commit is contained in:
Liav A 2020-02-24 00:59:00 +02:00 committed by Andreas Kling
parent 43d570a1e3
commit 85307dd26e
13 changed files with 91 additions and 102 deletions

View file

@ -38,7 +38,7 @@ namespace Kernel {
class ACPIDynamicParser final : public IRQHandler
, ACPIStaticParser {
public:
static void initialize(ACPI_RAW::RSDPDescriptor20& rsdp);
static void initialize(PhysicalAddress rsdp);
static void initialize_without_rsdp();
virtual void enable_aml_interpretation() override;
@ -49,7 +49,7 @@ public:
protected:
ACPIDynamicParser();
explicit ACPIDynamicParser(ACPI_RAW::RSDPDescriptor20&);
explicit ACPIDynamicParser(PhysicalAddress);
private:
void build_namespace();