From: Jan Beulich <jbeulich@suse.com>
To: Juergen Gross <jgross@suse.com>
Cc: Stefano Stabellini <sstabellini@kernel.org>,
Russell King <linux@armlinux.org.uk>,
Boris Ostrovsky <boris.ostrovsky@oracle.com>,
Thomas Gleixner <tglx@linutronix.de>,
Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>,
Dave Hansen <dave.hansen@linux.intel.com>,
"H. Peter Anvin" <hpa@zytor.com>,
Oleksandr Tyshchenko <oleksandr_tyshchenko@epam.com>,
xen-devel@lists.xenproject.org,
linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org, x86@kernel.org
Subject: Re: [PATCH] x86/xen: call xen_set_upcall_vector() only after local apic setup
Date: Mon, 14 Nov 2022 10:32:48 +0100 [thread overview]
Message-ID: <5ac0cc88-fb43-120c-975a-f1ad23ed30fb@suse.com> (raw)
In-Reply-To: <20221112132336.698-1-jgross@suse.com>
On 12.11.2022 14:23, Juergen Gross wrote:
> Calling xen_set_upcall_vector() before the local APIC has been
> initialized results in warnings when setting up the local APIC:
>
> [ 0.037322] APIC: Stale IRR: 00080000, ...
>
> Avoid this problem by moving the call of xen_set_upcall_vector() for
> APs from xen_cpu_up_prepare_hvm() to a new hotplug callback called on
> the AP before interrupts are enabled and after the local APIC has been
> initialized. There is already a Xen specific hotplug state defined at
> a matching position, but right now it is specific to Arm. So rename
> the CPUHP_AP_ARM_XEN_STARTING to CPUHP_AP_XEN_STARTING and use it for
> x86, too.
>
> On the boot processor use the x86_init.irqs.intr_mode_init hook to
> call xen_set_upcall_vector() only after the local APIC initialization.
> As interrupts are on already at the time when the hook is being used,
> modify xen_init_setup_upcall_vector() to disable interrupts. This is
> needed as the xen_percpu_upcall flag is set only after the callback
> has been registered, and the flag is needed for correctly acknowledging
> an interrupt.
>
> Fixes: b1c3497e604d ("x86/xen: Add support for HVMOP_set_evtchn_upcall_vector")
> Reported-by: Jan Beulich <jbeulich@suse.com>
> Signed-off-by: Juergen Gross <jgross@suse.com>
Just to mention it here - as per [1] the issue may instead result from
hypervisor misbehavior, so I guess we want to investigate that route
first.
Jan
[1] https://lists.xen.org/archives/html/xen-devel/2022-11/msg00783.html
prev parent reply other threads:[~2022-11-14 9:33 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-12 13:23 Juergen Gross
2022-11-14 9:32 ` Jan Beulich [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=5ac0cc88-fb43-120c-975a-f1ad23ed30fb@suse.com \
--to=jbeulich@suse.com \
--cc=boris.ostrovsky@oracle.com \
--cc=bp@alien8.de \
--cc=dave.hansen@linux.intel.com \
--cc=hpa@zytor.com \
--cc=jgross@suse.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@armlinux.org.uk \
--cc=mingo@redhat.com \
--cc=oleksandr_tyshchenko@epam.com \
--cc=sstabellini@kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@kernel.org \
--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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®