tests/libqos: embed allocators instead of malloc-ing them separately

qgraph will embed these objects instead of allocating them in a separate
object.  Expose a new API "generic_alloc_init" and "generic_alloc_destroy"
for that, and rename the existing API with s/init/new/ and s/uninit/free/.

Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
Paolo Bonzini 2018-11-29 12:37:04 +01:00
parent 143e6db6fa
commit eb5937bad6
21 changed files with 124 additions and 212 deletions

View file

@ -10,8 +10,6 @@
#include "libqos/malloc.h"
QGuestAllocator *spapr_alloc_init(void);
QGuestAllocator *spapr_alloc_init_flags(QTestState *qts, QAllocOpts flags);
void spapr_alloc_uninit(QGuestAllocator *allocator);
void spapr_alloc_init(QGuestAllocator *s, QTestState *qts, QAllocOpts flags);
#endif