1/*
2 * Copyright 2003-2007, Axel Dörfler, axeld@pinc-software.de. All rights reserved.
3 * Distributed under the terms of the MIT License.
4*/
5
6
7#include <boot/platform.h>
8
9#include <stdlib.h>
10#include <stdio.h>
11
12
13status_t
14platform_allocate_region(void **_address, size_t size, uint8 protection,
15	bool exactAddress)
16{
17	printf("platform_allocate_region(address = %p, size = %lu, protection = %u, exactAdress = %d)\n",
18		*_address, size, protection, exactAddress);
19
20	void *address = malloc(size);
21	if (address == NULL)
22		return B_NO_MEMORY;
23
24	*_address = address;
25	return B_OK;
26}
27
28
29status_t
30platform_free_region(void *address, size_t size)
31{
32	free(address);
33	return B_OK;
34}
35
36