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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CACRpkdaA5dgG3f8fEqkSny_uUYC_1nFu3=GAPtwS=aoy7qYsJg@mail.gmail.com>
Date:   Mon, 3 May 2021 15:56:01 +0200
From:   Linus Walleij <linus.walleij@...aro.org>
To:     Jonathan Cameron <jic23@...nel.org>
Cc:     "Sa, Nuno" <Nuno.Sa@...log.com>,
        Paul Cercueil <paul@...pouillou.net>,
        Lars-Peter Clausen <lars@...afoo.de>,
        Peter Meerwald-Stadler <pmeerw@...erw.net>,
        "linux-iio@...r.kernel.org" <linux-iio@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] tools/iio: iio_event_monitor: Fix ioctl error check

On Mon, May 3, 2021 at 1:05 PM Jonathan Cameron <jic23@...nel.org> wrote:

> So, I did a bit of detective work on this one.  Seems this change in error
> code was actually introduced as a side effect of Alex's recent rework of
> the IOCTLs.  Prior to that we returned -ENODEV for this case and now
> we do indeed return EINVAL.
>
> So we may need to figure out how to fix that, or decide that such is life
> and modify this code to give the right error message as done in this patch...
>
> Linus / Alex, thoughts?  It's always been a bit messy because we also
> return -ENODEV in the path where the ioctl hits a driver that is going away
> so it hasn't uniquely identified a lack of support for a long time, even
> if that is by far the most likely reason for this return code.

Normally this would be ABI if any existing userspace can break because
of the wrong error code being returned. Linus (the other one) has
clearly stated that the ABI is a contract that cannot be broken.

So I would just try to fix the errorpath to go back to returning -ENODEV.

Yours,
Linus Walleij

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ