863c623f9a
is fully covered by the ranges in the array. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36631 a95241bf-73f2-0310-859d-f6bbb57e9c96
40 lines
1.0 KiB
C
40 lines
1.0 KiB
C
/*
|
|
* Copyright 2004-2007, Axel Dörfler, axeld@pinc-software.de. All rights reserved.
|
|
* Distributed under the terms of the MIT License.
|
|
*/
|
|
#ifndef KERNEL_BOOT_ADDR_RANGE_H
|
|
#define KERNEL_BOOT_ADDR_RANGE_H
|
|
|
|
|
|
#include <SupportDefs.h>
|
|
|
|
|
|
typedef struct addr_range {
|
|
addr_t start;
|
|
addr_t size;
|
|
} addr_range;
|
|
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
status_t insert_address_range(addr_range *ranges, uint32 *_numRanges,
|
|
uint32 maxRanges, addr_t start, uint32 size);
|
|
status_t remove_address_range(addr_range *ranges, uint32 *_numRanges,
|
|
uint32 maxRanges, addr_t start, uint32 size);
|
|
bool get_free_address_range(addr_range *ranges, uint32 numRanges, addr_t base,
|
|
size_t size, addr_t *_rangeBase);
|
|
bool is_address_range_covered(addr_range *ranges, uint32 numRanges, addr_t base,
|
|
size_t size);
|
|
|
|
status_t insert_physical_memory_range(addr_t start, uint32 size);
|
|
status_t insert_physical_allocated_range(addr_t start, uint32 size);
|
|
status_t insert_virtual_allocated_range(addr_t start, uint32 size);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* KERNEL_BOOT_ADDR_RANGE_H */
|