diff options
author | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-07-15 23:19:18 +0000 |
---|---|---|
committer | Jonathan Gray <jsg@cvs.openbsd.org> | 2015-07-15 23:19:18 +0000 |
commit | 8fe18de6b71b21a55b7a6a1be7fdbe927c5802c2 (patch) | |
tree | 45caf22bc7f1b91249a630243a18973ed06f85df /lib/libdrm/intel/mm.h | |
parent | 6277fea1ff79f467de318738affc94191c925a73 (diff) |
update to libdrm 2.4.62
Diffstat (limited to 'lib/libdrm/intel/mm.h')
-rw-r--r-- | lib/libdrm/intel/mm.h | 36 |
1 files changed, 13 insertions, 23 deletions
diff --git a/lib/libdrm/intel/mm.h b/lib/libdrm/intel/mm.h index 8a5235b08..8d83743fd 100644 --- a/lib/libdrm/intel/mm.h +++ b/lib/libdrm/intel/mm.h @@ -29,6 +29,12 @@ #ifndef MM_H #define MM_H +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + +#include "libdrm_macros.h" + struct mem_block { struct mem_block *next, *prev; struct mem_block *next_free, *prev_free; @@ -38,21 +44,11 @@ struct mem_block { unsigned int reserved:1; }; -/* Rename the variables in the drm copy of this code so that it doesn't - * conflict with mesa or whoever else has copied it around. - */ -#define mmInit drm_mmInit -#define mmAllocMem drm_mmAllocMem -#define mmFreeMem drm_mmFreeMem -#define mmFindBlock drm_mmFindBlock -#define mmDestroy drm_mmDestroy -#define mmDumpMemInfo drm_mmDumpMemInfo - /** * input: total size in bytes * return: a heap pointer if OK, NULL if error */ -extern struct mem_block *mmInit(int ofs, int size); +drm_private extern struct mem_block *mmInit(int ofs, int size); /** * Allocate 'size' bytes with 2^align2 bytes alignment, @@ -64,31 +60,25 @@ extern struct mem_block *mmInit(int ofs, int size); * startSearch = linear offset from start of heap to begin search * return: pointer to the allocated block, 0 if error */ -extern struct mem_block *mmAllocMem(struct mem_block *heap, int size, - int align2, int startSearch); +drm_private extern struct mem_block *mmAllocMem(struct mem_block *heap, + int size, int align2, + int startSearch); /** * Free block starts at offset * input: pointer to a block * return: 0 if OK, -1 if error */ -extern int mmFreeMem(struct mem_block *b); - -/** - * Free block starts at offset - * input: pointer to a heap, start offset - * return: pointer to a block - */ -extern struct mem_block *mmFindBlock(struct mem_block *heap, int start); +drm_private extern int mmFreeMem(struct mem_block *b); /** * destroy MM */ -extern void mmDestroy(struct mem_block *mmInit); +drm_private extern void mmDestroy(struct mem_block *mmInit); /** * For debuging purpose. */ -extern void mmDumpMemInfo(const struct mem_block *mmInit); +drm_private extern void mmDumpMemInfo(const struct mem_block *mmInit); #endif |