2 * Copyright 2009, Haiku, Inc. All rights reserved.
3 * Distributed under the terms of the MIT License.
5 #ifndef _REALTIME_ALLOC_H
6 #define _REALTIME_ALLOC_H
9 #include <SupportDefs.h>
16 typedef struct rtm_pool rtm_pool
;
19 status_t
rtm_create_pool(rtm_pool
** _pool
, size_t totalSize
,
20 const char* name
= NULL
);
22 status_t
rtm_create_pool(rtm_pool
** _pool
, size_t totalSize
, const char* name
);
25 status_t
rtm_delete_pool(rtm_pool
* pool
);
27 void* rtm_alloc(rtm_pool
* pool
, size_t size
);
28 status_t
rtm_free(void* data
);
29 status_t
rtm_realloc(void** data
, size_t new_size
);
30 status_t
rtm_size_for(void* data
);
31 status_t
rtm_phys_size_for(void* data
);
32 size_t rtm_available(rtm_pool
* pool
);
34 rtm_pool
* rtm_default_pool();
40 #endif // _REALTIME_ALLOC_H