From owner-freebsd-arch@FreeBSD.ORG Fri Apr 1 14:58:33 2011 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7A6E81065672; Fri, 1 Apr 2011 14:58:33 +0000 (UTC) (envelope-from imp@bsdimp.com) Received: from harmony.bsdimp.com (bsdimp.com [199.45.160.85]) by mx1.freebsd.org (Postfix) with ESMTP id 383018FC14; Fri, 1 Apr 2011 14:58:33 +0000 (UTC) Received: from 63.imp.bsdimp.com (63.imp.bsdimp.com [10.0.0.63]) (authenticated bits=0) by harmony.bsdimp.com (8.14.4/8.14.3) with ESMTP id p31EpPiD040268 (version=TLSv1/SSLv3 cipher=DHE-DSS-AES128-SHA bits=128 verify=NO); Fri, 1 Apr 2011 08:51:25 -0600 (MDT) (envelope-from imp@bsdimp.com) Mime-Version: 1.0 (Apple Message framework v1082) Content-Type: text/plain; charset=us-ascii From: Warner Losh In-Reply-To: <4D95E162.40605@FreeBSD.org> Date: Fri, 1 Apr 2011 08:51:25 -0600 Content-Transfer-Encoding: quoted-printable Message-Id: References: <4D95E162.40605@FreeBSD.org> To: Andriy Gapon X-Mailer: Apple Mail (2.1082) X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.0.1 (harmony.bsdimp.com [10.0.0.6]); Fri, 01 Apr 2011 08:51:25 -0600 (MDT) Cc: FreeBSD Hackers , FreeBSD Arch Subject: Re: looking for error codes X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 01 Apr 2011 14:58:33 -0000 On Apr 1, 2011, at 8:29 AM, Andriy Gapon wrote: >=20 > I am looking for error codes that would unambiguously signal that a = disk drive has > readonly or write-protected media and that disk drive has no media at = the moment. > I foresee these error codes being used mostly between disk peripheral = drivers and > filesystem drivers. >=20 > I will appreciate your suggestions. >=20 > P.S. > I see that Linux uses EROFS and ENOMEDIUM for these purposes. > I am not sure about EROFS in this role. > And we don't have ENOMEDIUM (nor EMEDIUMTYPE). Maybe we could add ENOMEDIA for that (spelled however Linux spells it) = after EDAVE. Warner