All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dma-buf: add support for compat ioctl
       [not found] <CGME20170221132114eucas1p2e527d5b5516494ba54aa91f48b3e227f@eucas1p2.samsung.com>
@ 2017-02-21 13:21   ` Marek Szyprowski
  0 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 13:21 UTC (permalink / raw)
  To: linux-media, dri-devel
  Cc: Marek Szyprowski, Sumit Semwal, linaro-mm-sig, linux-kernel,
	Bartlomiej Zolnierkiewicz

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 <m.szyprowski@samsung.com>
---
 drivers/dma-buf/dma-buf.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
index 718f832a5c71..0007b792827b 100644
--- a/drivers/dma-buf/dma-buf.c
+++ b/drivers/dma-buf/dma-buf.c
@@ -325,6 +325,9 @@ static long dma_buf_ioctl(struct file *file,
 	.llseek		= dma_buf_llseek,
 	.poll		= dma_buf_poll,
 	.unlocked_ioctl	= dma_buf_ioctl,
+#ifdef CONFIG_COMPAT
+	.compat_ioctl	= dma_buf_ioctl,
+#endif
 };
 
 /*
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-21 13:21   ` Marek Szyprowski
  0 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 13:21 UTC (permalink / raw)
  To: linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz, Marek Szyprowski

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 <m.szyprowski@samsung.com>
---
 drivers/dma-buf/dma-buf.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
index 718f832a5c71..0007b792827b 100644
--- a/drivers/dma-buf/dma-buf.c
+++ b/drivers/dma-buf/dma-buf.c
@@ -325,6 +325,9 @@ static long dma_buf_ioctl(struct file *file,
 	.llseek		= dma_buf_llseek,
 	.poll		= dma_buf_poll,
 	.unlocked_ioctl	= dma_buf_ioctl,
+#ifdef CONFIG_COMPAT
+	.compat_ioctl	= dma_buf_ioctl,
+#endif
 };
 
 /*
-- 
1.9.1

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply related	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-21 13:21   ` Marek Szyprowski
@ 2017-02-21 13:59     ` Christian König
  -1 siblings, 0 replies; 14+ messages in thread
From: Christian König @ 2017-02-21 13:59 UTC (permalink / raw)
  To: Marek Szyprowski, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
> 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.

Well I might be wrong, but IIRC compat_ioctl was just optional and if 
not specified unlocked_ioctl was called instead.

If that is true your patch wouldn't have any effect at all.

Regards,
Christian.

>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>   drivers/dma-buf/dma-buf.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
> index 718f832a5c71..0007b792827b 100644
> --- a/drivers/dma-buf/dma-buf.c
> +++ b/drivers/dma-buf/dma-buf.c
> @@ -325,6 +325,9 @@ static long dma_buf_ioctl(struct file *file,
>   	.llseek		= dma_buf_llseek,
>   	.poll		= dma_buf_poll,
>   	.unlocked_ioctl	= dma_buf_ioctl,
> +#ifdef CONFIG_COMPAT
> +	.compat_ioctl	= dma_buf_ioctl,
> +#endif
>   };
>   
>   /*

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-21 13:59     ` Christian König
  0 siblings, 0 replies; 14+ messages in thread
From: Christian König @ 2017-02-21 13:59 UTC (permalink / raw)
  To: Marek Szyprowski, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
> 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.

Well I might be wrong, but IIRC compat_ioctl was just optional and if 
not specified unlocked_ioctl was called instead.

If that is true your patch wouldn't have any effect at all.

Regards,
Christian.

>
> Signed-off-by: Marek Szyprowski <m.szyprowski@samsung.com>
> ---
>   drivers/dma-buf/dma-buf.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
> index 718f832a5c71..0007b792827b 100644
> --- a/drivers/dma-buf/dma-buf.c
> +++ b/drivers/dma-buf/dma-buf.c
> @@ -325,6 +325,9 @@ static long dma_buf_ioctl(struct file *file,
>   	.llseek		= dma_buf_llseek,
>   	.poll		= dma_buf_poll,
>   	.unlocked_ioctl	= dma_buf_ioctl,
> +#ifdef CONFIG_COMPAT
> +	.compat_ioctl	= dma_buf_ioctl,
> +#endif
>   };
>   
>   /*


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-21 13:59     ` Christian König
@ 2017-02-21 14:37       ` Marek Szyprowski
  -1 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 14:37 UTC (permalink / raw)
  To: Christian König, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Hi Christian,

On 2017-02-21 14:59, Christian König wrote:
> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>> 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.
>
> Well I might be wrong, but IIRC compat_ioctl was just optional and if 
> not specified unlocked_ioctl was called instead.
>
> If that is true your patch wouldn't have any effect at all.

Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
64bit ARM64 kernel without this patch?

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-21 14:37       ` Marek Szyprowski
  0 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 14:37 UTC (permalink / raw)
  To: Christian König, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Hi Christian,

On 2017-02-21 14:59, Christian König wrote:
> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>> 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.
>
> Well I might be wrong, but IIRC compat_ioctl was just optional and if 
> not specified unlocked_ioctl was called instead.
>
> If that is true your patch wouldn't have any effect at all.

Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
64bit ARM64 kernel without this patch?

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-21 14:37       ` Marek Szyprowski
@ 2017-02-21 14:55         ` Marek Szyprowski
  -1 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 14:55 UTC (permalink / raw)
  To: Christian König, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Dear All,

On 2017-02-21 15:37, Marek Szyprowski wrote:
> Hi Christian,
>
> On 2017-02-21 14:59, Christian König wrote:
>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>> 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.
>>
>> Well I might be wrong, but IIRC compat_ioctl was just optional and if 
>> not specified unlocked_ioctl was called instead.
>>
>> If that is true your patch wouldn't have any effect at all.
>
> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
> 64bit ARM64 kernel without this patch?
>

I've checked in fs/compat_ioctl.c, I see no fallback in 
COMPAT_SYSCALL_DEFINE3,
so one has to provide compat_ioctl callback to have ioctl working with 32bit
apps.

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-21 14:55         ` Marek Szyprowski
  0 siblings, 0 replies; 14+ messages in thread
From: Marek Szyprowski @ 2017-02-21 14:55 UTC (permalink / raw)
  To: Christian König, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Dear All,

On 2017-02-21 15:37, Marek Szyprowski wrote:
> Hi Christian,
>
> On 2017-02-21 14:59, Christian König wrote:
>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>> 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.
>>
>> Well I might be wrong, but IIRC compat_ioctl was just optional and if 
>> not specified unlocked_ioctl was called instead.
>>
>> If that is true your patch wouldn't have any effect at all.
>
> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
> 64bit ARM64 kernel without this patch?
>

I've checked in fs/compat_ioctl.c, I see no fallback in 
COMPAT_SYSCALL_DEFINE3,
so one has to provide compat_ioctl callback to have ioctl working with 32bit
apps.

Best regards
-- 
Marek Szyprowski, PhD
Samsung R&D Institute Poland

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-21 14:55         ` Marek Szyprowski
@ 2017-02-21 15:08           ` Christian König
  -1 siblings, 0 replies; 14+ messages in thread
From: Christian König @ 2017-02-21 15:08 UTC (permalink / raw)
  To: Marek Szyprowski, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
> Dear All,
>
> On 2017-02-21 15:37, Marek Szyprowski wrote:
>> Hi Christian,
>>
>> On 2017-02-21 14:59, Christian König wrote:
>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>> 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.
>>>
>>> Well I might be wrong, but IIRC compat_ioctl was just optional and 
>>> if not specified unlocked_ioctl was called instead.
>>>
>>> If that is true your patch wouldn't have any effect at all.
>>
>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
>> 64bit ARM64 kernel without this patch?
>>
>
> I've checked in fs/compat_ioctl.c, I see no fallback in 
> COMPAT_SYSCALL_DEFINE3,
> so one has to provide compat_ioctl callback to have ioctl working with 
> 32bit
> apps.

Then my memory cheated on me.

In this case the patch is Reviewed-by: Christian König 
<christian.koenig@amd.com>.

Regards,
Christian.

>
> Best regards

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-21 15:08           ` Christian König
  0 siblings, 0 replies; 14+ messages in thread
From: Christian König @ 2017-02-21 15:08 UTC (permalink / raw)
  To: Marek Szyprowski, linux-media, dri-devel
  Cc: linaro-mm-sig, linux-kernel, Bartlomiej Zolnierkiewicz

Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
> Dear All,
>
> On 2017-02-21 15:37, Marek Szyprowski wrote:
>> Hi Christian,
>>
>> On 2017-02-21 14:59, Christian König wrote:
>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>> 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.
>>>
>>> Well I might be wrong, but IIRC compat_ioctl was just optional and 
>>> if not specified unlocked_ioctl was called instead.
>>>
>>> If that is true your patch wouldn't have any effect at all.
>>
>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on 
>> 64bit ARM64 kernel without this patch?
>>
>
> I've checked in fs/compat_ioctl.c, I see no fallback in 
> COMPAT_SYSCALL_DEFINE3,
> so one has to provide compat_ioctl callback to have ioctl working with 
> 32bit
> apps.

Then my memory cheated on me.

In this case the patch is Reviewed-by: Christian König 
<christian.koenig@amd.com>.

Regards,
Christian.

>
> Best regards


_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-21 15:08           ` Christian König
@ 2017-02-22 19:07             ` Daniel Vetter
  -1 siblings, 0 replies; 14+ messages in thread
From: Daniel Vetter @ 2017-02-22 19:07 UTC (permalink / raw)
  To: Christian König
  Cc: Marek Szyprowski, linux-media, dri-devel, linaro-mm-sig,
	Linux Kernel Mailing List, Bartlomiej Zolnierkiewicz

On Tue, Feb 21, 2017 at 4:08 PM, Christian König
<deathsimple@vodafone.de> wrote:
> Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
>>
>> Dear All,
>>
>> On 2017-02-21 15:37, Marek Szyprowski wrote:
>>>
>>> Hi Christian,
>>>
>>> On 2017-02-21 14:59, Christian König wrote:
>>>>
>>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>>>
>>>>> 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.
>>>>
>>>>
>>>> Well I might be wrong, but IIRC compat_ioctl was just optional and if
>>>> not specified unlocked_ioctl was called instead.
>>>>
>>>> If that is true your patch wouldn't have any effect at all.
>>>
>>>
>>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on
>>> 64bit ARM64 kernel without this patch?
>>>
>>
>> I've checked in fs/compat_ioctl.c, I see no fallback in
>> COMPAT_SYSCALL_DEFINE3,
>> so one has to provide compat_ioctl callback to have ioctl working with
>> 32bit
>> apps.
>
>
> Then my memory cheated on me.
>
> In this case the patch is Reviewed-by: Christian König
> <christian.koenig@amd.com>.

Since you have commit rights for drm-misc, care to push this to
drm-misc-next-fixes pls? Also I think this warrants a cc: stable,
clearly an obvious screw-up in creating this api on our side :( So
feel free to smash my ack on the patch.

Thanks, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-22 19:07             ` Daniel Vetter
  0 siblings, 0 replies; 14+ messages in thread
From: Daniel Vetter @ 2017-02-22 19:07 UTC (permalink / raw)
  To: Christian König
  Cc: Bartlomiej Zolnierkiewicz, Linux Kernel Mailing List, dri-devel,
	linaro-mm-sig, Marek Szyprowski, linux-media

On Tue, Feb 21, 2017 at 4:08 PM, Christian König
<deathsimple@vodafone.de> wrote:
> Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
>>
>> Dear All,
>>
>> On 2017-02-21 15:37, Marek Szyprowski wrote:
>>>
>>> Hi Christian,
>>>
>>> On 2017-02-21 14:59, Christian König wrote:
>>>>
>>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>>>
>>>>> 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.
>>>>
>>>>
>>>> Well I might be wrong, but IIRC compat_ioctl was just optional and if
>>>> not specified unlocked_ioctl was called instead.
>>>>
>>>> If that is true your patch wouldn't have any effect at all.
>>>
>>>
>>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on
>>> 64bit ARM64 kernel without this patch?
>>>
>>
>> I've checked in fs/compat_ioctl.c, I see no fallback in
>> COMPAT_SYSCALL_DEFINE3,
>> so one has to provide compat_ioctl callback to have ioctl working with
>> 32bit
>> apps.
>
>
> Then my memory cheated on me.
>
> In this case the patch is Reviewed-by: Christian König
> <christian.koenig@amd.com>.

Since you have commit rights for drm-misc, care to push this to
drm-misc-next-fixes pls? Also I think this warrants a cc: stable,
clearly an obvious screw-up in creating this api on our side :( So
feel free to smash my ack on the patch.

Thanks, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
  2017-02-22 19:07             ` Daniel Vetter
@ 2017-02-23  6:37               ` Sumit Semwal
  -1 siblings, 0 replies; 14+ messages in thread
From: Sumit Semwal @ 2017-02-23  6:37 UTC (permalink / raw)
  To: Daniel Vetter
  Cc: Christian König, Bartlomiej Zolnierkiewicz,
	Linux Kernel Mailing List, dri-devel, linaro-mm-sig,
	Marek Szyprowski, linux-media

Hi Marek,

On 23 February 2017 at 00:37, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Tue, Feb 21, 2017 at 4:08 PM, Christian König
> <deathsimple@vodafone.de> wrote:
>> Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
>>>
>>> Dear All,
>>>
>>> On 2017-02-21 15:37, Marek Szyprowski wrote:
>>>>
>>>> Hi Christian,
>>>>
>>>> On 2017-02-21 14:59, Christian König wrote:
>>>>>
>>>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>>>>
>>>>>> 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.
>>>>>
>>>>>
>>>>> Well I might be wrong, but IIRC compat_ioctl was just optional and if
>>>>> not specified unlocked_ioctl was called instead.
>>>>>
>>>>> If that is true your patch wouldn't have any effect at all.
>>>>
>>>>
>>>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on
>>>> 64bit ARM64 kernel without this patch?
>>>>
>>>
>>> I've checked in fs/compat_ioctl.c, I see no fallback in
>>> COMPAT_SYSCALL_DEFINE3,
>>> so one has to provide compat_ioctl callback to have ioctl working with
>>> 32bit
>>> apps.
>>
>>
>> Then my memory cheated on me.
>>
>> In this case the patch is Reviewed-by: Christian König
>> <christian.koenig@amd.com>.
>

Thanks much for spotting this!

> Since you have commit rights for drm-misc, care to push this to
> drm-misc-next-fixes pls? Also I think this warrants a cc: stable,
> clearly an obvious screw-up in creating this api on our side :( So
> feel free to smash my ack on the patch.
>
Daniel, Christian,

I saw this just now, so if Christian hasn't already pulled it into
drm-misc-next-fixes, I'll give it a stab.

> Thanks, Daniel
> --
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

Best,
Sumit.

-- 
Thanks and regards,

Sumit Semwal
Linaro Mobile Group - Kernel Team Lead
Linaro.org │ Open source software for ARM SoCs

^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: [PATCH] dma-buf: add support for compat ioctl
@ 2017-02-23  6:37               ` Sumit Semwal
  0 siblings, 0 replies; 14+ messages in thread
From: Sumit Semwal @ 2017-02-23  6:37 UTC (permalink / raw)
  To: Daniel Vetter
  Cc: Bartlomiej Zolnierkiewicz, Linux Kernel Mailing List, dri-devel,
	linaro-mm-sig, linux-media, Marek Szyprowski

Hi Marek,

On 23 February 2017 at 00:37, Daniel Vetter <daniel@ffwll.ch> wrote:
> On Tue, Feb 21, 2017 at 4:08 PM, Christian König
> <deathsimple@vodafone.de> wrote:
>> Am 21.02.2017 um 15:55 schrieb Marek Szyprowski:
>>>
>>> Dear All,
>>>
>>> On 2017-02-21 15:37, Marek Szyprowski wrote:
>>>>
>>>> Hi Christian,
>>>>
>>>> On 2017-02-21 14:59, Christian König wrote:
>>>>>
>>>>> Am 21.02.2017 um 14:21 schrieb Marek Szyprowski:
>>>>>>
>>>>>> 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.
>>>>>
>>>>>
>>>>> Well I might be wrong, but IIRC compat_ioctl was just optional and if
>>>>> not specified unlocked_ioctl was called instead.
>>>>>
>>>>> If that is true your patch wouldn't have any effect at all.
>>>>
>>>>
>>>> Well, then why I got -ENOTTY in the 32bit test app for this ioctl on
>>>> 64bit ARM64 kernel without this patch?
>>>>
>>>
>>> I've checked in fs/compat_ioctl.c, I see no fallback in
>>> COMPAT_SYSCALL_DEFINE3,
>>> so one has to provide compat_ioctl callback to have ioctl working with
>>> 32bit
>>> apps.
>>
>>
>> Then my memory cheated on me.
>>
>> In this case the patch is Reviewed-by: Christian König
>> <christian.koenig@amd.com>.
>

Thanks much for spotting this!

> Since you have commit rights for drm-misc, care to push this to
> drm-misc-next-fixes pls? Also I think this warrants a cc: stable,
> clearly an obvious screw-up in creating this api on our side :( So
> feel free to smash my ack on the patch.
>
Daniel, Christian,

I saw this just now, so if Christian hasn't already pulled it into
drm-misc-next-fixes, I'll give it a stab.

> Thanks, Daniel
> --
> Daniel Vetter
> Software Engineer, Intel Corporation
> +41 (0) 79 365 57 48 - http://blog.ffwll.ch
> _______________________________________________
> dri-devel mailing list
> dri-devel@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/dri-devel

Best,
Sumit.

-- 
Thanks and regards,

Sumit Semwal
Linaro Mobile Group - Kernel Team Lead
Linaro.org │ Open source software for ARM SoCs
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2017-02-23  6:43 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20170221132114eucas1p2e527d5b5516494ba54aa91f48b3e227f@eucas1p2.samsung.com>
2017-02-21 13:21 ` [PATCH] dma-buf: add support for compat ioctl Marek Szyprowski
2017-02-21 13:21   ` Marek Szyprowski
2017-02-21 13:59   ` Christian König
2017-02-21 13:59     ` Christian König
2017-02-21 14:37     ` Marek Szyprowski
2017-02-21 14:37       ` Marek Szyprowski
2017-02-21 14:55       ` Marek Szyprowski
2017-02-21 14:55         ` Marek Szyprowski
2017-02-21 15:08         ` Christian König
2017-02-21 15:08           ` Christian König
2017-02-22 19:07           ` Daniel Vetter
2017-02-22 19:07             ` Daniel Vetter
2017-02-23  6:37             ` Sumit Semwal
2017-02-23  6:37               ` Sumit Semwal

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.