mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-04-12 01:10:19 +08:00
dma-buf: align fd_flags and heap_flags with dma_heap_allocation_data
dma_heap_allocation_data defines the UAPI as follows:
struct dma_heap_allocation_data {
__u64 len;
__u32 fd;
__u32 fd_flags;
__u64 heap_flags;
};
However, dma_heap_buffer_alloc() casts both fd_flags and heap_flags
into unsigned int. We're inconsistent with types in the non UAPI
arguments. This patch fixes it.
Signed-off-by: Barry Song <v-songbaohua@oppo.com>
Acked-by: John Stultz <jstultz@google.com>
Signed-off-by: Sumit Semwal <sumit.semwal@linaro.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20240605012605.5341-1-21cnbao@gmail.com
This commit is contained in:
@@ -19,7 +19,7 @@
|
||||
#define DMA_HEAP_VALID_FD_FLAGS (O_CLOEXEC | O_ACCMODE)
|
||||
|
||||
/* Currently no heap flags */
|
||||
#define DMA_HEAP_VALID_HEAP_FLAGS (0)
|
||||
#define DMA_HEAP_VALID_HEAP_FLAGS (0ULL)
|
||||
|
||||
/**
|
||||
* struct dma_heap_allocation_data - metadata passed from userspace for
|
||||
|
||||
Reference in New Issue
Block a user