From: Bryan O'Donoghue <bryan.odonoghue.lkml-SyKdqv6vbfZdzvEItQ6vdLNAH6kLmebB@public.gmane.org>
To: Greg KH <gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org>
Cc: matt-HNK1S37rvNbeXh+fF434Mdi2O/JbrIOy@public.gmane.org,
matthew.garrett-05XSO3Yj/JvQT0dZR+AlfA@public.gmane.org,
linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
darren.hart-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org,
josh-iaAMLnmF4UmaiuxdJuQwMA@public.gmane.org,
hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org,
mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org
Subject: Re: [PATCH] Remove warning in efi_enter_virtual_mode V2
Date: Fri, 19 Apr 2013 12:15:23 +0100 [thread overview]
Message-ID: <5171274B.7090500@nexus-software.ie> (raw)
In-Reply-To: <20130419055813.GA16443-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
On 19/04/13 06:58, Greg KH wrote:
>> This patch gives the option to switch off that behavior - if your BIOS
>> has neither BGRT - nor bugs that require mapping of EFI boot code/data
>
> No, never add new boot options, no users, or distros, know to set them.
> Isn't there some way we can dynamically determine this instead?
Peter, Greg.
There are three issues to consider here
1: Some UEFI BIOS is buggy and the EFI_RUNTIME_SERVICES code - actually
touches EFI_BOOT_MEMORY. Boot memory should be completely untouched
after an entity calls ExitBootServices() - typically done by an EFI
aware bootloader before handing off to Linux.
2: Existing code maps EFI_BOOT_MEMORY in arch/x86/platform/efi/efi.c.
Initially it looked to me as though you could probe for ACPI::BGRT -
look for an ACPI object sometimes stored in EFI_BOOT_MEMORY and use that
to determine if EFI_BOOT_MEMORY should be mapped. I wasn't aware #1
above was also a concern. So just probing for something - doesn't appear
to fly
3: Standards compliant EFI BIOS - like the reference EFI 2.3.1 code we
have on my project, has neither of the two above problems to work around
So we can.
1. Just silently map EFI_BOOT_MEMORY - even on unbuggy platforms like #3
- or we can
2. Introduce some sort of intelligence - a parameter somewhere to tell
the efi_enter_virtual mode if/when to map EFI_BOOT_MEMORY.
3. Just go the suggested route from Josh
#ifdef CONFIG_X86_64
if (md->type != EFI_BOOT_SERVICES_CODE &&
md->type != EFI_BOOT_SERVICES_DATA)
#endif
Option #3 - so long as it doesn't break ia32::BGRT systems works for me.
prev parent reply other threads:[~2013-04-19 11:15 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-04-17 22:05 [PATCH] Remove warning in efi_enter_virtual_mode V2 Bryan O'Donoghue
[not found] ` <1366236341-22615-1-git-send-email-bryan.odonoghue.lkml-SyKdqv6vbfZdzvEItQ6vdLNAH6kLmebB@public.gmane.org>
2013-04-19 5:58 ` Greg KH
[not found] ` <20130419055813.GA16443-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2013-04-19 6:00 ` H. Peter Anvin
[not found] ` <bb2db2a1-835f-47d0-830d-0dd3785343a9-2ueSQiBKiTY7tOexoI0I+QC/G2K4zDHf@public.gmane.org>
2013-04-19 6:11 ` Greg KH
[not found] ` <20130419061146.GA16775-U8xfFu+wG4EAvxtiuMwx3w@public.gmane.org>
2013-04-19 6:17 ` H. Peter Anvin
2013-04-19 11:15 ` Bryan O'Donoghue [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5171274B.7090500@nexus-software.ie \
--to=bryan.odonoghue.lkml-sykdqv6vbfzdzveitq6vdlnah6klmebb@public.gmane.org \
--cc=darren.hart-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org \
--cc=gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org \
--cc=hpa-YMNOUZJC4hwAvxtiuMwx3w@public.gmane.org \
--cc=josh-iaAMLnmF4UmaiuxdJuQwMA@public.gmane.org \
--cc=linux-efi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=matt-HNK1S37rvNbeXh+fF434Mdi2O/JbrIOy@public.gmane.org \
--cc=matthew.garrett-05XSO3Yj/JvQT0dZR+AlfA@public.gmane.org \
--cc=mingo-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=tglx-hfZtesqFncYOwBW4kG4KsQ@public.gmane.org \
--cc=x86-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox