kernel/vm: use DoublyLinkedList for VMCache areas list
Change-Id: I0c6a231f245fa542f5d90959755de1e6ba39eb8e Reviewed-on: https://review.haiku-os.org/c/haiku/+/8685 Reviewed-by: waddlesplash <[email protected]>
This commit is contained in:
@@ -119,8 +119,13 @@ public:
|
||||
uint8* page_protections;
|
||||
|
||||
struct VMAddressSpace* address_space;
|
||||
struct VMArea* cache_next;
|
||||
struct VMArea* cache_prev;
|
||||
|
||||
private:
|
||||
DoublyLinkedListLink<VMArea> fCacheLink;
|
||||
|
||||
public:
|
||||
typedef DoublyLinkedList<VMArea,
|
||||
DoublyLinkedListMemberGetLink<VMArea, &VMArea::fCacheLink> > CacheList;
|
||||
|
||||
addr_t Base() const { return fBase; }
|
||||
size_t Size() const { return fSize; }
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <util/DoublyLinkedList.h>
|
||||
#include <vm/vm.h>
|
||||
#include <vm/vm_types.h>
|
||||
#include <vm/VMArea.h>
|
||||
|
||||
#include "kernel_debug_config.h"
|
||||
|
||||
@@ -188,7 +189,7 @@ protected:
|
||||
virtual void DeleteObject() = 0;
|
||||
|
||||
public:
|
||||
VMArea* areas;
|
||||
VMArea::CacheList areas;
|
||||
ConsumerList consumers;
|
||||
// list of caches that use this cache as a source
|
||||
VMCachePagesTree pages;
|
||||
|
||||
Reference in New Issue
Block a user