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: <49B30FC4.5040305@imap.cc>
Date:	Sun, 08 Mar 2009 01:22:28 +0100
From:	Tilman Schmidt <tilman@...p.cc>
To:	Arjan van de Ven <arjan@...radead.org>
CC:	davem@...emloft.net, linux-kernel@...r.kernel.org,
	netdev@...r.kernel.org, Paul Bolle <pebolle@...cali.nl>,
	Hansjoerg Lipp <hjlipp@....de>
Subject: Re: [PATCH 1/2] gigaset: return -ENOSYS for unimplemented functions

Am 07.03.2009 23:26 schrieb Arjan van de Ven:
> On Sat,  7 Mar 2009 23:10:57 +0100 (CET)
> Tilman Schmidt <tilman@...p.cc> wrote:
> 
>> From: Paul Bolle <pebolle@...cali.nl>
>>
>> A number of functions in the usb_gigaset module will return -EINVAL if
>> CONFIG_GIGASET_UNDOCREQ is not set. Make these return -ENOSYS as it's
>> more specific and it might make it easier to see (from userspace) why
>> these functions actually fail.
>>
>> Impact: some error return codes changed
> 
> ENODEV is what would be more appropriate.

Not at all. ENODEV means "no such device", which would be quite wrong.
The device does exist and is in all probability working perfectly fine.
It just doesn't implement that particular ioctl.

> ENOSYS shuoldn't be returned from drivers, only from unimplemented
> system calls!

There's precedent for using ENOSYS for that case, for example in
drivers/char/vt_ioctl.c. But I'm open for other suggestions.

Thanks,
Tilman

-- 
Tilman Schmidt                    E-Mail: tilman@...p.cc
Bonn, Germany
Diese Nachricht besteht zu 100% aus wiederverwerteten Bits.
Ungeöffnet mindestens haltbar bis: (siehe Rückseite)


Download attachment "signature.asc" of type "application/pgp-signature" (255 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ