diff options
author | Rob Clark <robdclark@gmail.com> | 2015-09-04 20:04:01 -0400 |
---|---|---|
committer | Rob Clark <robdclark@gmail.com> | 2015-09-04 20:04:01 -0400 |
commit | 1dbce3f196486f77a16f0b32bffb915990450673 (patch) | |
tree | 8b06c45a92a7a2f76aa0cd78f3f9a524d1469256 | |
parent | 9a316c8bdbed33c7ac07462928d6cd633188decb (diff) | |
download | drm_gralloc-1dbce3f196486f77a16f0b32bffb915990450673.tar.gz |
WIP: hook drm debug traces up to android log stuff
-rw-r--r-- | gralloc_drm.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/gralloc_drm.c b/gralloc_drm.c index 3f3f529..93a01b4 100644 --- a/gralloc_drm.c +++ b/gralloc_drm.c @@ -110,6 +110,17 @@ init_drv_from_fd(int fd) return drv; } +static int drm_debug_print(const char *format, va_list ap) +{ + __android_log_vprint(ANDROID_LOG_INFO, LOG_TAG, format, ap); + return 0; +} + + +static const drmServerInfo server_info = { + .debug_print = drm_debug_print, +}; + /* * Create a DRM device object. */ @@ -135,6 +146,8 @@ struct gralloc_drm_t *gralloc_drm_create(void) return NULL; } + drmSetServerInfo(&server_info); + return drm; } |