From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1PVh9A-0001tt-JA for mharc-grub-devel@gnu.org; Thu, 23 Dec 2010 04:07:40 -0500 Received: from [140.186.70.92] (port=58948 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PVh98-0001qp-7Z for grub-devel@gnu.org; Thu, 23 Dec 2010 04:07:39 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PVh96-0004H7-KP for grub-devel@gnu.org; Thu, 23 Dec 2010 04:07:38 -0500 Received: from mail-qy0-f169.google.com ([209.85.216.169]:49287) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PVh96-0004H3-Gz for grub-devel@gnu.org; Thu, 23 Dec 2010 04:07:36 -0500 Received: by qyk7 with SMTP id 7so6732014qyk.0 for ; Thu, 23 Dec 2010 01:07:35 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:content-type :content-transfer-encoding; bh=kpr0UoJQUMkRpMdDjG1JkgffxT5q9KBGv51lMIYH120=; b=QtTSHQDK58+/0a+IUdOZEfK2mFbIM6pLxpUNju/Sx0XZ/XNm/fA3Ffp2dfliYMsvd3 ug8RwR62eSTJIyFpevBRvLkMMPgM+wThOswaLKourNlATkzQUyzFp2t9IVay+jtMi+ei OkWyWO0OmcVcCLPuhXlTsVnXdb/OfURBPjwuc= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type:content-transfer-encoding; b=Lr4sGyG88v8U+9ZzC8ABrJDeXN+1wF66OlF/g43ZNaHupaLQMRG8mj2CX4Ms3XUA+P yereYrc/xdqfHwxOKpagYfSd1oVr+4MSLP9Dz15jiEtPG5AbUbdxOKLWrgkbGhwVld83 tekdWu8xQJii/PrOZKXOpdlLnBxhbH1Tw4hLE= Received: by 10.224.73.130 with SMTP id q2mr7506669qaj.160.1293095255820; Thu, 23 Dec 2010 01:07:35 -0800 (PST) MIME-Version: 1.0 Received: by 10.220.29.5 with HTTP; Thu, 23 Dec 2010 01:07:15 -0800 (PST) In-Reply-To: <20101123152936.GF21862@riva.ucam.org> References: <20101123152936.GF21862@riva.ucam.org> From: Jordan Uggla Date: Thu, 23 Dec 2010 01:07:15 -0800 Message-ID: To: The development of GNU GRUB Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) Subject: [PATCH] Re: ACPI halt failures in tests X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Dec 2010 09:07:39 -0000 On Tue, Nov 23, 2010 at 7:29 AM, Colin Watson wrote: > I occasionally get "ACPI shutdown failed" in qemu during tests. =A0Since > this is printed with grub_printf rather than with grub_dprintf or > whatever, it shows up in the test output and causes tests to fail. =A0It > only fails some of the time on my system (less than half). =A0I've tried > to insert 'set debug=3Dacpi' into the grub-shell test setup, but it > stubbornly succeeds when I do that, so I'm not really sure what else to > try. > > The system seems to shut down happily anyway, presumably because it goes > on to try other boot methods. =A0Should we maybe downgrade this to a debu= g > message? I think it's more likely a race condition of sorts; it's assumed that the code that prints "ACPI shutdown failed" is unreachable when ACPI shutdown succeeds, since the code comes after shutdown has been requested. Part of the reason I think this is that the symptom I've been seeing is just "A" or "AC" being printed, which means that the shutdown is not synchronous (it's happening in the middle of a printf). Since in real hardware I can't see this being much of a problem (except maybe causing false alarms for people who log serial output), and it would be good to have some type of message on the screen when ACPI shutdown does fail, I don't think this should be just a dprintf. Instead I think that the unit test's grub.cfg should disable serial terminal just before running halt as a work around. =3D=3D=3D modified file 'ChangeLog' --- ChangeLog 2010-12-10 12:56:45 +0000 +++ ChangeLog 2010-12-23 09:02:56 +0000 @@ -1,3 +1,7 @@ +2010-12-23 Jordan Uggal + * tests/util/grub-shell.in: Supress "ACPI shutdown failed" error + to keep unit tests from failing when they shouldn't. + 2010-12-10 Colin Watson * .bzrignore: Ignore grub-core/rs_decoder.S. =3D=3D=3D modified file 'tests/util/grub-shell.in' --- tests/util/grub-shell.in 2010-10-18 20:50:01 +0000 +++ tests/util/grub-shell.in 2010-12-23 09:04:34 +0000 @@ -132,6 +132,8 @@ cat <>${cfgfile} source /boot/grub/testcase.cfg +terminal_output console # Stop serial output to supress + # "ACPI shutdown failed" error. halt EOF --=20 Jordan Uggla (Jordan_U on irc.freenode.net)