From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Hellstrom Subject: ENOENT as an ioctl return code Date: Tue, 03 Dec 2013 21:09:40 +0100 Message-ID: <529E3A84.5030404@shipmail.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: Received: from mx2.bahnhof.se (mx2.bahnhof.se [213.80.101.12]) by gabe.freedesktop.org (Postfix) with ESMTP id E19CAFB6EA for ; Tue, 3 Dec 2013 12:09:56 -0800 (PST) List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces@lists.freedesktop.org Errors-To: dri-devel-bounces@lists.freedesktop.org To: =?ISO-8859-1?Q?Ville_Syrj=E4l=E4?= , "dri-devel@lists.freedesktop.org" List-Id: dri-devel@lists.freedesktop.org Hi, By concidence I ran across this lkml message http://marc.info/?l=linux-kernel&m=135628421403144&w=2 with an important part in the middle: (this is not a drm commit) To make matters worse, commit f0ed2ce840b3 is clearly total and utter CRAP even if it didn't break applications. ENOENT is not a valid error return from an ioctl. Never has been, never will be. ENOENT means "No such file and directory", and is for path operations. ioctl's are done on files that have already been opened, there's no way in hell that ENOENT would ever be valid. Perhaps we should rethink the use of ENOENT when not finding mode objects? Thanks, Thomas