History

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.

Barry Song committed 2 years ago

Commit 310ec031 parent 9c3951e2 files · +3 −3Browse files

Showing the changes to include/uapi (1 of 2 files). Show all

Unified · Split

include/uapi/linux/dma-heap.h+1−1
@@ -19,7 +19,7 @@ · 18 unmodified lines
1919 #define DMA_HEAP_VALID_FD_FLAGS (O_CLOEXEC | O_ACCMODE)
2020
2121 /* Currently no heap flags */
22−#define DMA_HEAP_VALID_HEAP_FLAGS (0)
22+#define DMA_HEAP_VALID_HEAP_FLAGS (0ULL)
2323
2424 /**
2525 * struct dma_heap_allocation_data - metadata passed from userspace for