mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:48:10 +00:00
Kernel: Allow specifying a physical alignment when allocating
Some drivers may require allocating contiguous physical pages with a specific alignment for the physical address.
This commit is contained in:
parent
d5472426ec
commit
affb4ef01b
6 changed files with 29 additions and 23 deletions
|
@ -35,10 +35,10 @@ class ContiguousVMObject final : public VMObject {
|
|||
public:
|
||||
virtual ~ContiguousVMObject() override;
|
||||
|
||||
static NonnullRefPtr<ContiguousVMObject> create_with_size(size_t);
|
||||
static NonnullRefPtr<ContiguousVMObject> create_with_size(size_t, size_t physical_alignment = PAGE_SIZE);
|
||||
|
||||
private:
|
||||
explicit ContiguousVMObject(size_t);
|
||||
explicit ContiguousVMObject(size_t, size_t physical_alignment);
|
||||
explicit ContiguousVMObject(const ContiguousVMObject&);
|
||||
|
||||
virtual const char* class_name() const override { return "ContiguousVMObject"; }
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue