Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 10 Nov 2010 09:07:09 -0700
From:      Scott Long <scottl@samsco.org>
To:        David Rhodus <sdrhodus@gmail.com>
Cc:        "current@freebsd.org" <current@freebsd.org>
Subject:   Re: Only display ACPI bootmenu key if ACPI is present
Message-ID:  <CE00D43B-BEE6-458C-99D8-0C3B77B73D7D@samsco.org>
In-Reply-To: <D625EC79-3929-40C4-9AB8-2C33B12A2E9A@gmail.com>
References:  <201011081714.53637.jhb@freebsd.org> <D625EC79-3929-40C4-9AB8-2C33B12A2E9A@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
If the loader can't detect acpi, the kernel can't either.

Scott

On Nov 10, 2010, at 9:01 AM, David Rhodus wrote:

> 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 ?
>=20
> Thanks,
> David Rhodus
>=20
> On Nov 8, 2010, at 5:14 PM, John Baldwin <jhb@freebsd.org> wrote:
>=20
>> 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 avoids
>> displaying a menu item prompting to enable ACPI if the BIOS doesn't =
actually
>> 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"
> _______________________________________________
> 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"




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CE00D43B-BEE6-458C-99D8-0C3B77B73D7D>