From 51b5ca9457a241e9f005359a99fdff1886fe5e72 Mon Sep 17 00:00:00 2001 From: Rob Clark Date: Fri, 4 Sep 2015 11:08:04 -0400 Subject: freedreno: add API to get drm fd from fd_device Signed-off-by: Rob Clark --- freedreno/freedreno-symbol-check | 1 + freedreno/freedreno_device.c | 5 +++++ freedreno/freedreno_drmif.h | 1 + 3 files changed, 7 insertions(+) (limited to 'freedreno') diff --git a/freedreno/freedreno-symbol-check b/freedreno/freedreno-symbol-check index e593df4d..f517b6e7 100755 --- a/freedreno/freedreno-symbol-check +++ b/freedreno/freedreno-symbol-check @@ -25,6 +25,7 @@ fd_bo_new fd_bo_ref fd_bo_size fd_device_del +fd_device_fd fd_device_new fd_device_new_dup fd_device_ref diff --git a/freedreno/freedreno_device.c b/freedreno/freedreno_device.c index 3bc4cb21..ddb95455 100644 --- a/freedreno/freedreno_device.c +++ b/freedreno/freedreno_device.c @@ -160,3 +160,8 @@ void fd_device_del(struct fd_device *dev) fd_device_del_impl(dev); pthread_mutex_unlock(&table_lock); } + +int fd_device_fd(struct fd_device *dev) +{ + return dev->fd; +} diff --git a/freedreno/freedreno_drmif.h b/freedreno/freedreno_drmif.h index 81a14b43..5547e943 100644 --- a/freedreno/freedreno_drmif.h +++ b/freedreno/freedreno_drmif.h @@ -76,6 +76,7 @@ struct fd_device * fd_device_new(int fd); struct fd_device * fd_device_new_dup(int fd); struct fd_device * fd_device_ref(struct fd_device *dev); void fd_device_del(struct fd_device *dev); +int fd_device_fd(struct fd_device *dev); /* pipe functions: -- cgit v1.2.3