From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1L69AG-00071H-KQ for mharc-grub-devel@gnu.org; Fri, 28 Nov 2008 14:38:08 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L69AE-00070J-FP for grub-devel@gnu.org; Fri, 28 Nov 2008 14:38:06 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L69AC-0006zK-OF for grub-devel@gnu.org; Fri, 28 Nov 2008 14:38:05 -0500 Received: from [199.232.76.173] (port=38281 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L69AC-0006zA-KD for grub-devel@gnu.org; Fri, 28 Nov 2008 14:38:04 -0500 Received: from aybabtu.com ([69.60.117.155]:53301) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1L69AC-0006rX-AT for grub-devel@gnu.org; Fri, 28 Nov 2008 14:38:04 -0500 Received: from [192.168.10.10] (helo=thorin) by aybabtu.com with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1L697D-000811-9K for grub-devel@gnu.org; Fri, 28 Nov 2008 20:34:59 +0100 Received: from rmh by thorin with local (Exim 4.63) (envelope-from ) id 1L699b-00026b-Gy for grub-devel@gnu.org; Fri, 28 Nov 2008 20:37:27 +0100 Date: Fri, 28 Nov 2008 20:37:27 +0100 From: Robert Millan To: The development of GRUB 2 Message-ID: <20081128193727.GA7980@thorin> References: <20081122153509.GA576@thorin> <200811252217.18586.okuji@enbug.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200811252217.18586.okuji@enbug.org> Organization: free as in freedom X-Message-Flag: Worried about Outlook viruses? Switch to Thunderbird! www.mozilla.com/thunderbird X-Debbugs-No-Ack: true User-Agent: Mutt/1.5.13 (2006-08-11) X-detected-operating-system: by monty-python.gnu.org: Genre and OS details not recognized. Subject: Re: [PATCH] (ata.mod) avoid passing grub_errno to upper layer X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Nov 2008 19:38:06 -0000 On Tue, Nov 25, 2008 at 10:17:17PM +0100, Yoshinori K. Okuji wrote: > On Saturday 22 November 2008 16:35:09 Robert Millan wrote: > > When an error is detected by ata.mod during drive scan, it will pass it to > > the upper layer. This results in GRUB aborting when trying to enter normal > > mode, even if the error is not critical (e.g. affects a drive not used > > during boot). > > > > There are a number of places in ata.mod where these errors could be > > handled, so I'm not sure if my proposed change would be the best approach. > > Some comment would be appreciated. > > This is one way, but I think the upper layer should be more robust against > errors raised from modules. For example, we can unload a module, and clear > GRUB_ERRNO, if the init function in this module return an error. But if the error is specific to a device unit, unloading the module would result in all units of this device class being disabled, which is most likely not what we want. -- Robert Millan The DRM opt-in fallacy: "Your data belongs to us. We will decide when (and how) you may access your data; but nobody's threatening your freedom: we still allow you to remove your data and not access it at all."