mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 18:07:34 +00:00
Kernel: Make Region splitting OOM-safe
Region allocation failures during splitting are now propagated all the way out to where we can return ENOMEM for them.
This commit is contained in:
parent
cac557eee0
commit
cd7a49b90d
3 changed files with 40 additions and 16 deletions
|
@ -42,8 +42,8 @@ public:
|
|||
bool deallocate_region(Region& region);
|
||||
OwnPtr<Region> take_region(Region& region);
|
||||
|
||||
Region& allocate_split_region(const Region& source_region, const Range&, size_t offset_in_vmobject);
|
||||
Vector<Region*, 2> split_region_around_range(const Region& source_region, const Range&);
|
||||
KResultOr<Region*> try_allocate_split_region(Region const& source_region, Range const&, size_t offset_in_vmobject);
|
||||
KResultOr<Vector<Region*, 2>> try_split_region_around_range(Region const& source_region, Range const&);
|
||||
|
||||
Region* find_region_from_range(const Range&);
|
||||
Region* find_region_containing(const Range&);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue