#include <unistd.h>
#include <string.h>
#include <errno.h>
+#include <pipebuffer/pb_bufmgr.h>
#include "xf86drm.h"
#include "radeon_priv.h"
#include "radeon_drm.h"
__func__, radeon->device);
break;
}
+
+ radeon->mman = pb_malloc_bufmgr_create();
+ if (!radeon->mman)
+ return NULL;
+ radeon->kman = radeon_bo_pbmgr_create(radeon);
+ if (!radeon->kman)
+ return NULL;
return radeon;
}
if (--radeon->refcount > 0) {
return NULL;
}
+
+ radeon->mman->destroy(radeon->mman);
+ radeon->kman->destroy(radeon->kman);
drmClose(radeon->fd);
free(radeon);
return NULL;