From owner-freebsd-hackers@FreeBSD.ORG Wed Aug 5 00:15:51 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 44EEA106564A for ; Wed, 5 Aug 2009 00:15:51 +0000 (UTC) (envelope-from mel.flynn+fbsd.hackers@mailing.thruhere.net) Received: from mailhub.rachie.is-a-geek.net (rachie.is-a-geek.net [66.230.99.27]) by mx1.freebsd.org (Postfix) with ESMTP id 13EC48FC14 for ; Wed, 5 Aug 2009 00:15:50 +0000 (UTC) (envelope-from mel.flynn+fbsd.hackers@mailing.thruhere.net) Received: from smoochies.rachie.is-a-geek.net (mailhub.rachie.is-a-geek.net [192.168.2.11]) by mailhub.rachie.is-a-geek.net (Postfix) with ESMTP id 008E77E818; Tue, 4 Aug 2009 16:15:49 -0800 (AKDT) From: Mel Flynn To: freebsd-hackers@freebsd.org Date: Tue, 4 Aug 2009 16:15:48 -0800 User-Agent: KMail/1.11.4 (FreeBSD/8.0-BETA2; KDE/4.2.4; i386; ; ) References: <200908041245.35926.mel.flynn+fbsd.hackers@mailing.thruhere.net> <4A78AB7C.3040406@andric.com> In-Reply-To: <4A78AB7C.3040406@andric.com> MIME-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200908041615.49128.mel.flynn+fbsd.hackers@mailing.thruhere.net> Cc: Dimitry Andric Subject: Re: Spot the error X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Aug 2009 00:15:51 -0000 On Tuesday 04 August 2009 13:43:24 Dimitry Andric wrote: > On 2009-08-04 22:45, Mel Flynn wrote: > > % mount -t msdofs /dev/label/camera ~/camera > > mount: /dev/label/camera : Operation not supported by device > > > > I would expect something along the lines of "unknown file system type". > > Is this fixable? > > Yes, just use "msdosfs" instead. ;) That said, it looks like ENODEV is > returned by vfs_domount(), whenever the fs type is not found in the > list of supported filesystems: > > [...] > if (fsflags & MNT_ROOTFS) > vfsp = vfs_byname(fstype); > else > vfsp = vfs_byname_kld(fstype, td, &error); > if (vfsp == NULL) > return (ENODEV); > [...] > > Note that in the case when vfs_byname_kld() gets called, the error it > returns is silently thrown away. What a pity. :) > > In any case, you could paint a lot of bikesheds about which error code > from errno.h would be most suited for this situation, unfortunately. I would expect "Unable to load fs: " + ENOENT. I was asking if this was fixable, cause it looked like the code has been abstracted to the point that specific errors were hard, but maybe I missed something. -- Mel