From owner-freebsd-current@FreeBSD.ORG Wed Nov 10 16:01:55 2010 Return-Path: Delivered-To: current@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B3D63106564A; Wed, 10 Nov 2010 16:01:55 +0000 (UTC) (envelope-from sdrhodus@gmail.com) Received: from mail-gy0-f182.google.com (mail-gy0-f182.google.com [209.85.160.182]) by mx1.freebsd.org (Postfix) with ESMTP id 57D748FC0A; Wed, 10 Nov 2010 16:01:55 +0000 (UTC) Received: by gya6 with SMTP id 6so472006gya.13 for ; Wed, 10 Nov 2010 08:01:54 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:references:in-reply-to :mime-version:content-transfer-encoding:content-type:message-id:cc :x-mailer:from:subject:date:to; bh=BM8gmP8n1wVj2UMz7NZjyKtyJtTZDnfM76AxWO9/A44=; b=FcaVitzZnd9q7ejhSZEG3YMHfJCq0q5VYGmLZC+MvkjG8snXFjbTHCIonkToijTqRE nAXIrfLLlW8I+HQMlAZeEQewageBF986qMpzm9jMjQ5LnOO8SoBh99pvnxCCe3mIMdem PXdIKjVQeILbtWnNaKD0IZ9J+LpTnI3qbPXk8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=references:in-reply-to:mime-version:content-transfer-encoding :content-type:message-id:cc:x-mailer:from:subject:date:to; b=gJKBVBVDZ+p4LXfBzMriz5te0JowBgyVewfsOrEEX5TihqMHo30E3sAjHFyGIGAZux mWAEjEWwBlF7ft2q53CDQcUA7J+IUZ21ZQi2CE2g4RSW8/8p9P4JBOQ7IQZDr8KiWUME 9NWZcSKIkM9QcVXldNEdhcfclu0oGEh56cga4= Received: by 10.151.79.1 with SMTP id g1mr11491494ybl.375.1289404914609; Wed, 10 Nov 2010 08:01:54 -0800 (PST) Received: from [10.79.254.223] ([166.137.12.90]) by mx.google.com with ESMTPS id q8sm1691980ybk.0.2010.11.10.08.01.50 (version=TLSv1/SSLv3 cipher=RC4-MD5); Wed, 10 Nov 2010 08:01:52 -0800 (PST) References: <201011081714.53637.jhb@freebsd.org> In-Reply-To: <201011081714.53637.jhb@freebsd.org> Mime-Version: 1.0 (iPhone Mail 8B117) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=us-ascii Message-Id: X-Mailer: iPhone Mail (8B117) From: David Rhodus Date: Wed, 10 Nov 2010 11:01:32 -0500 To: John Baldwin Cc: "current@freebsd.org" Subject: Re: Only display ACPI bootmenu key if ACPI is present X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Nov 2010 16:01:55 -0000 What are the chances the detection fails and one still needs to disable ACPI= and can't because it's not showing as a option ? Thanks, David Rhodus On Nov 8, 2010, at 5:14 PM, John Baldwin wrote: > This patch changes the Forth code for the Beastie menu to only display the= > menu option to enable or disable ACPI if the loader detects ACPI. This av= oids > displaying a menu item prompting to enable ACPI if the BIOS doesn't actual= ly > include ACPI. Any objections? >=20 > --- //depot/projects/smpng/sys/boot/forth/beastie.4th 2010-11-08 21:53:= 18.000000000 0000 > +++ //depot/user/jhb/ktrace/boot/forth/beastie.4th 2010-11-08 22:14:04.= 000000000 0000 > @@ -140,12 +140,16 @@ > fbsdbw-logo > ; >=20 > -: acpienabled? ( -- flag ) > +: acpipresent? ( -- flag ) > s" hint.acpi.0.rsdp" getenv > dup -1 =3D if > drop false exit > then > 2drop > + true > +; > + > +: acpienabled? ( -- flag ) > s" hint.acpi.0.disabled" getenv > dup -1 <> if > s" 0" compare 0<> if > @@ -178,8 +182,7 @@ > 42 20 2 2 box > 13 6 at-xy ." Welcome to FreeBSD!" > printmenuitem ." Boot FreeBSD [default]" bootkey ! > - s" arch-i386" environment? if > - drop > + acpipresent? if > printmenuitem ." Boot FreeBSD with ACPI " bootacpikey ! > acpienabled? if > ." disabled" >=20 > --=20 > John Baldwin > _______________________________________________ > freebsd-current@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-current > To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"=