From f07e572f6447465d8938679533d604e402b0f066 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= Date: Thu, 18 Feb 2021 18:04:33 +0100 Subject: bcm27xx: import latest patches from the RPi foundation MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit bcm2708: boot tested on RPi B+ v1.2 bcm2709: boot tested on RPi 3B v1.2 and RPi 4B v1.1 4G bcm2710: boot tested on RPi 3B v1.2 bcm2711: boot tested on RPi 4B v1.1 4G Signed-off-by: Álvaro Fernández Rojas --- ...ps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch | 69 ++++++++++++++++++++++ 1 file changed, 69 insertions(+) create mode 100644 target/linux/bcm27xx/patches-5.4/950-0727-dma-buf-heaps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch (limited to 'target/linux/bcm27xx/patches-5.4/950-0727-dma-buf-heaps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch') diff --git a/target/linux/bcm27xx/patches-5.4/950-0727-dma-buf-heaps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch b/target/linux/bcm27xx/patches-5.4/950-0727-dma-buf-heaps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch new file mode 100644 index 0000000000..a949831525 --- /dev/null +++ b/target/linux/bcm27xx/patches-5.4/950-0727-dma-buf-heaps-Use-_IOCTL_-for-userspace-IOCTL-identi.patch @@ -0,0 +1,69 @@ +From 8153056fa1d45394057017843070d3a366dbd918 Mon Sep 17 00:00:00 2001 +From: "Andrew F. Davis" +Date: Mon, 16 Dec 2019 08:34:04 -0500 +Subject: [PATCH] dma-buf: heaps: Use _IOCTL_ for userspace IOCTL + identifier + +Commit b3b4346544b571c96d46be615b9db69a601ce4c8 upstream. + +This is more consistent with the DMA and DRM frameworks convention. This +patch is only a name change, no logic is changed. + +Signed-off-by: Andrew F. Davis +Acked-by: John Stultz +Signed-off-by: Sumit Semwal +Link: https://patchwork.freedesktop.org/patch/msgid/20191216133405.1001-2-afd@ti.com +--- + drivers/dma-buf/dma-heap.c | 4 ++-- + include/uapi/linux/dma-heap.h | 4 ++-- + tools/testing/selftests/dmabuf-heaps/dmabuf-heap.c | 2 +- + 3 files changed, 5 insertions(+), 5 deletions(-) + +--- a/drivers/dma-buf/dma-heap.c ++++ b/drivers/dma-buf/dma-heap.c +@@ -107,7 +107,7 @@ static long dma_heap_ioctl_allocate(stru + } + + unsigned int dma_heap_ioctl_cmds[] = { +- DMA_HEAP_IOC_ALLOC, ++ DMA_HEAP_IOCTL_ALLOC, + }; + + static long dma_heap_ioctl(struct file *file, unsigned int ucmd, +@@ -153,7 +153,7 @@ static long dma_heap_ioctl(struct file * + memset(kdata + in_size, 0, ksize - in_size); + + switch (kcmd) { +- case DMA_HEAP_IOC_ALLOC: ++ case DMA_HEAP_IOCTL_ALLOC: + ret = dma_heap_ioctl_allocate(file, kdata); + break; + default: +--- a/include/uapi/linux/dma-heap.h ++++ b/include/uapi/linux/dma-heap.h +@@ -42,12 +42,12 @@ struct dma_heap_allocation_data { + #define DMA_HEAP_IOC_MAGIC 'H' + + /** +- * DOC: DMA_HEAP_IOC_ALLOC - allocate memory from pool ++ * DOC: DMA_HEAP_IOCTL_ALLOC - allocate memory from pool + * + * Takes a dma_heap_allocation_data struct and returns it with the fd field + * populated with the dmabuf handle of the allocation. + */ +-#define DMA_HEAP_IOC_ALLOC _IOWR(DMA_HEAP_IOC_MAGIC, 0x0,\ ++#define DMA_HEAP_IOCTL_ALLOC _IOWR(DMA_HEAP_IOC_MAGIC, 0x0,\ + struct dma_heap_allocation_data) + + #endif /* _UAPI_LINUX_DMABUF_POOL_H */ +--- a/tools/testing/selftests/dmabuf-heaps/dmabuf-heap.c ++++ b/tools/testing/selftests/dmabuf-heaps/dmabuf-heap.c +@@ -116,7 +116,7 @@ static int dmabuf_heap_alloc_fdflags(int + if (!dmabuf_fd) + return -EINVAL; + +- ret = ioctl(fd, DMA_HEAP_IOC_ALLOC, &data); ++ ret = ioctl(fd, DMA_HEAP_IOCTL_ALLOC, &data); + if (ret < 0) + return ret; + *dmabuf_fd = (int)data.fd; -- cgit v1.2.3