diff options
author | RajithaY <rajithax.yerrumsetty@intel.com> | 2017-04-25 03:31:15 -0700 |
---|---|---|
committer | Rajitha Yerrumchetty <rajithax.yerrumsetty@intel.com> | 2017-05-22 06:48:08 +0000 |
commit | bb756eebdac6fd24e8919e2c43f7d2c8c4091f59 (patch) | |
tree | ca11e03542edf2d8f631efeca5e1626d211107e3 /qemu/roms/seabios/src/malloc.h | |
parent | a14b48d18a9ed03ec191cf16b162206998a895ce (diff) |
Adding qemu as a submodule of KVMFORNFV
This Patch includes the changes to add qemu as a submodule to
kvmfornfv repo and make use of the updated latest qemu for the
execution of all testcase
Change-Id: I1280af507a857675c7f81d30c95255635667bdd7
Signed-off-by:RajithaY<rajithax.yerrumsetty@intel.com>
Diffstat (limited to 'qemu/roms/seabios/src/malloc.h')
-rw-r--r-- | qemu/roms/seabios/src/malloc.h | 70 |
1 files changed, 0 insertions, 70 deletions
diff --git a/qemu/roms/seabios/src/malloc.h b/qemu/roms/seabios/src/malloc.h deleted file mode 100644 index 960a7f800..000000000 --- a/qemu/roms/seabios/src/malloc.h +++ /dev/null @@ -1,70 +0,0 @@ -#ifndef __MALLOC_H -#define __MALLOC_H - -#include "types.h" // u32 - -// malloc.c -extern struct zone_s ZoneLow, ZoneHigh, ZoneFSeg, ZoneTmpLow, ZoneTmpHigh; -u32 rom_get_max(void); -u32 rom_get_last(void); -struct rom_header *rom_reserve(u32 size); -int rom_confirm(u32 size); -void malloc_csm_preinit(u32 low_pmm, u32 low_pmm_size, u32 hi_pmm, - u32 hi_pmm_size); -void malloc_preinit(void); -extern u32 LegacyRamSize; -void malloc_init(void); -void malloc_prepboot(void); -u32 malloc_palloc(struct zone_s *zone, u32 size, u32 align); -void *_malloc(struct zone_s *zone, u32 size, u32 align); -int malloc_pfree(u32 data); -void free(void *data); -u32 malloc_getspace(struct zone_s *zone); -void malloc_sethandle(u32 data, u32 handle); -u32 malloc_findhandle(u32 handle); - -#define MALLOC_DEFAULT_HANDLE 0xFFFFFFFF -// Minimum alignment of malloc'd memory -#define MALLOC_MIN_ALIGN 16 -// Helper functions for memory allocation. -static inline void *malloc_low(u32 size) { - return _malloc(&ZoneLow, size, MALLOC_MIN_ALIGN); -} -static inline void *malloc_high(u32 size) { - return _malloc(&ZoneHigh, size, MALLOC_MIN_ALIGN); -} -static inline void *malloc_fseg(u32 size) { - return _malloc(&ZoneFSeg, size, MALLOC_MIN_ALIGN); -} -static inline void *malloc_tmplow(u32 size) { - return _malloc(&ZoneTmpLow, size, MALLOC_MIN_ALIGN); -} -static inline void *malloc_tmphigh(u32 size) { - return _malloc(&ZoneTmpHigh, size, MALLOC_MIN_ALIGN); -} -static inline void *malloc_tmp(u32 size) { - void *ret = malloc_tmphigh(size); - if (ret) - return ret; - return malloc_tmplow(size); -} -static inline void *memalign_low(u32 align, u32 size) { - return _malloc(&ZoneLow, size, align); -} -static inline void *memalign_high(u32 align, u32 size) { - return _malloc(&ZoneHigh, size, align); -} -static inline void *memalign_tmplow(u32 align, u32 size) { - return _malloc(&ZoneTmpLow, size, align); -} -static inline void *memalign_tmphigh(u32 align, u32 size) { - return _malloc(&ZoneTmpHigh, size, align); -} -static inline void *memalign_tmp(u32 align, u32 size) { - void *ret = memalign_tmphigh(align, size); - if (ret) - return ret; - return memalign_tmplow(align, size); -} - -#endif // malloc.h |