All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Marek Marczykowski-Górecki" <marmarek@invisiblethingslab.com>
To: Jan Beulich <jbeulich@suse.com>
Cc: "Teddy Astie" <teddy.astie@vates.tech>,
	"Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Anthony PERARD" <anthony.perard@vates.tech>,
	"Michal Orzel" <michal.orzel@amd.com>,
	"Julien Grall" <julien@xen.org>,
	"Roger Pau Monné" <roger.pau@citrix.com>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	"Daniel P. Smith" <dpsmith@apertussolutions.com>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH] efi: Enable EFI_SET_VIRTUAL_ADDRESS_MAP by default
Date: Fri, 6 Feb 2026 12:52:18 +0100	[thread overview]
Message-ID: <aYXV8o4LjGLQ0VaE@mail-itl> (raw)
In-Reply-To: <be09e51c-5201-4837-9921-5ac0d8cae582@suse.com>

[-- Attachment #1: Type: text/plain, Size: 2685 bytes --]

On Fri, Feb 06, 2026 at 07:29:49AM +0100, Jan Beulich wrote:
> On 05.02.2026 18:27, Teddy Astie wrote:
> > Many machines fail to boot if this option is disabled, as
> > there are no known drawback toggling this option, enable it
> > by default.
> 
> "no known drawback" ignores why it wasn't enabled originally. Imo this
> wants at least mentioning, if not discussing.

Relevant discussion was at https://lore.kernel.org/xen-devel/4e46a667-da69-9f25-387e-4dd45db10cda@suse.com/
(previous attempt at switching the default)

And also, (large) part of the reason for this being off by default
initially was it being close to 4.13 release:
https://lore.kernel.org/xen-devel/272a9354-bcb4-50a4-a251-6a453221d6e3@citrix.com/

Now it's substantially earlier in the 4.22 release cycle.

But yes, some note in patch description would be nice.

> > --- a/xen/common/Kconfig
> > +++ b/xen/common/Kconfig
> > @@ -363,13 +363,14 @@ config KEXEC
> >  
> >  config EFI_SET_VIRTUAL_ADDRESS_MAP
> >      bool "EFI: call SetVirtualAddressMap()" if EXPERT
> > +    default y
> >      help
> >        Call EFI SetVirtualAddressMap() runtime service to setup memory map for
> >        further runtime services. According to UEFI spec, it isn't strictly
> >        necessary, but many UEFI implementations misbehave when this call is
> >        missing.
> >  
> > -      If unsure, say N.
> > +      If unsure, say Y.
> 
> When this was added, it was actually hacked in with the aim of minimal
> intrusiveness. When we now default it to on, I wonder if other changes
> shouldn't be made (maybe not right in this patch, but perhaps in a
> single series). For example, identity mapping (with its implied
> restrictions) ought to be possible to do away with when the option is
> enabled. Whether the separate EFI page tables would still be needed
> also is questionable.

This is an interesting question, but IMHO the current approach is safer
(or rather: more reliable) - which is relevant given how many UEFI
systems are not exactly spec compliant...
One approach that could be tried is to mirror what Linux does, but I
don't see it as necessary for flipping the default. And in fact I would
rather prefer to not do that at the same time - the current approach is
battle tested by several downstream projects on a large number of
systems.

> I further wonder whether the EXPERT dependency of the prompt wouldn't
> better be dropped when flipping the default.

IMO the EXPERT dependency is still relevant. This option is basically
"break Xen on a large number of UEFI systems".

-- 
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2026-02-06 11:52 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-05 17:27 [PATCH] efi: Enable EFI_SET_VIRTUAL_ADDRESS_MAP by default Teddy Astie
2026-02-06  6:29 ` Jan Beulich
2026-02-06 11:52   ` Marek Marczykowski-Górecki [this message]
2026-02-06 12:04     ` Marek Marczykowski-Górecki

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=aYXV8o4LjGLQ0VaE@mail-itl \
    --to=marmarek@invisiblethingslab.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=anthony.perard@vates.tech \
    --cc=dpsmith@apertussolutions.com \
    --cc=jbeulich@suse.com \
    --cc=julien@xen.org \
    --cc=michal.orzel@amd.com \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=teddy.astie@vates.tech \
    --cc=xen-devel@lists.xenproject.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.