From 30632cec54048944ee364781b4b8c2676ae5dfed Mon Sep 17 00:00:00 2001 From: Sami Kiminki Date: Mon, 26 Oct 2015 19:23:54 +0200 Subject: gpu: nvgpu: Implement NVGPU_GPU_IOCTL_GET_BUFFER_INFO Implement NVGPU_GPU_IOCTL_GET_BUFFER_INFO. The new IOCTL can be used to identify buffers and retrieve their sizes. This allows the userspace to be agnostic to the dmabuf implementation, as the generic dmabuf fd interface does not have a reliable way for buffer identification. Bug 1614735 Bug 1623949 Bug 1660392 Change-Id: Ic3dd0a9385c9852778110ccb80636dd6f4f36208 Signed-off-by: Sami Kiminki Reviewed-on: http://git-master/r/822845 Reviewed-on: http://git-master/r/833252 Reviewed-by: Terje Bergstrom --- drivers/gpu/nvgpu/gk20a/mm_gk20a.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers/gpu/nvgpu/gk20a/mm_gk20a.h') diff --git a/drivers/gpu/nvgpu/gk20a/mm_gk20a.h b/drivers/gpu/nvgpu/gk20a/mm_gk20a.h index 7bbaf283..7be4383b 100644 --- a/drivers/gpu/nvgpu/gk20a/mm_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/mm_gk20a.h @@ -688,4 +688,7 @@ static inline void nvgpu_free(void *p) vfree(p); } +int gk20a_mm_get_buffer_info(struct device *dev, int dmabuf_fd, + u64 *buffer_id, u64 *buffer_len); + #endif /* MM_GK20A_H */ -- cgit v1.2.2