lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-id: <ac1ddfe4-1667-bdb0-c4da-35c8cf85fbed@samsung.com>
Date:   Tue, 21 Feb 2017 15:55:02 +0100
From:   Marek Szyprowski <m.szyprowski@...sung.com>
To:     Christian König <deathsimple@...afone.de>,
        linux-media@...r.kernel.org, dri-devel@...ts.freedesktop.org
Cc:     linaro-mm-sig@...ts.linaro.org, linux-kernel@...r.kernel.org,
        Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>
Subject: Re: [PATCH] dma-buf: add support for compat ioctl

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ