From da9fe49b94561d3126d4b2b0365dd29b7ad8b6a4 Mon Sep 17 00:00:00 2001 From: Greg Kroah-Hartman Date: Sun, 16 Apr 2017 10:00:56 +0200 Subject: [PATCH] 4.10-stable patches added patches: dma-buf-add-support-for-compat-ioctl.patch --- ...dma-buf-add-support-for-compat-ioctl.patch | 40 +++++++++++++++++++ queue-4.10/series | 1 + 2 files changed, 41 insertions(+) create mode 100644 queue-4.10/dma-buf-add-support-for-compat-ioctl.patch diff --git a/queue-4.10/dma-buf-add-support-for-compat-ioctl.patch b/queue-4.10/dma-buf-add-support-for-compat-ioctl.patch new file mode 100644 index 00000000000..a7c68d270d4 --- /dev/null +++ b/queue-4.10/dma-buf-add-support-for-compat-ioctl.patch @@ -0,0 +1,40 @@ +From 888022c0473d079bff9b47fb50434b1f20f8f37f Mon Sep 17 00:00:00 2001 +From: Marek Szyprowski +Date: Tue, 21 Feb 2017 14:21:01 +0100 +Subject: dma-buf: add support for compat ioctl +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +From: Marek Szyprowski + +commit 888022c0473d079bff9b47fb50434b1f20f8f37f upstream. + +Add compat ioctl support to dma-buf. This lets one to use DMA_BUF_IOCTL_SYNC +ioctl from 32bit application on 64bit kernel. Data structures for both 32 +and 64bit modes are same, so there is no need for additional translation +layer. + +Signed-off-by: Marek Szyprowski +Reviewed-by: Christian König +Acked-by: Daniel Vetter +Signed-off-by: Sumit Semwal +Link: http://patchwork.freedesktop.org/patch/msgid/1487683261-2655-1-git-send-email-m.szyprowski@samsung.com +Signed-off-by: Greg Kroah-Hartman + +--- + drivers/dma-buf/dma-buf.c | 3 +++ + 1 file changed, 3 insertions(+) + +--- a/drivers/dma-buf/dma-buf.c ++++ b/drivers/dma-buf/dma-buf.c +@@ -303,6 +303,9 @@ static const struct file_operations dma_ + .llseek = dma_buf_llseek, + .poll = dma_buf_poll, + .unlocked_ioctl = dma_buf_ioctl, ++#ifdef CONFIG_COMPAT ++ .compat_ioctl = dma_buf_ioctl, ++#endif + }; + + /* diff --git a/queue-4.10/series b/queue-4.10/series index 44028e9cd7e..3ad41990eaf 100644 --- a/queue-4.10/series +++ b/queue-4.10/series @@ -26,3 +26,4 @@ mips-irq-stack-fix-erroneous-jal-to-plat_irq_dispatch.patch crypto-caam-fix-rng-deinstantiation-error-checking.patch crypto-caam-fix-invalid-dereference-in-caam_rsa_init_tfm.patch net-packet-fix-overflow-in-check-for-priv-area-size.patch +dma-buf-add-support-for-compat-ioctl.patch -- 2.47.3