From: Bandan Das <bsd@redhat.com>
To: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Thomas Gleixner <tglx@linutronix.de>,
Chris Wilson <chris@chris-wilson.co.uk>,
Linux List Kernel Mailing <linux-kernel@vger.kernel.org>
Subject: Re: Linux 5.3-rc7
Date: Mon, 09 Sep 2019 09:54:13 -0400 [thread overview]
Message-ID: <jpga7bdpoca.fsf@linux.bootlegged.copy> (raw)
In-Reply-To: CAHk-=wimjeOCi4k7+nhzx3XWzvQUbMtNpcKNo8ZteodQ5c5APg@mail.gmail.com
Linus Torvalds <torvalds@linux-foundation.org> writes:
> On Sat, Sep 7, 2019 at 12:17 PM Linus Torvalds
> <torvalds@linux-foundation.org> wrote:
>>
>> I'm really not clear on why it's a good idea to clear the LDR bits on
>> shutdown, and commit 558682b52919 ("x86/apic: Include the LDR when
>> clearing out APIC registers") just looks pointless. And now it has
>> proven to break some machines.
>>
>> So why wouldn't we just revert it?
>
> Side note: looking around for the discussion about this patch, at
> least one version of the patch from Bandan had
>
> + if (!x2apic_enabled) {
>
> rather than
>
> + if (!x2apic_enabled()) {
>
I believe this crept up by accident when I was preparing the series, my testing
was with x2apic_enabled() but I didn't test CPU hotplug - only the kdump path
with 32 bit guest. In hindsight, I should have been more careful with testing,
sorry about that.
Bandan
> which meant that whatever Bandan tested at that point was actually a
> complete no-op, since "!x2apic_enabled" is never true (it tests a
> function pointer against NULL, which it won't be).
>
> Then that was fixed by the time it hit -tip (and eventually my tree),
> but it kind of shows how the patch history of this is all
> questionable. Further strengthened by a quote from that discussion:
>
> "this is really a KVM bug but it doesn't hurt to clear out the LDR in
> the guest and then, it wouldn't need a hypervisor fix"
>
> and clearly it *does* hurt to clear the LDR in the guest, making the
> whole thinking behind the patch wrong and broken. The kernel clearly
> _does_ depend on LDR having the right contents.
>
> Now, I still suspect the boot problem then comes from our
> cpu0_logical_apicid use mentioned in that previous email, but at this
> point I think the proper fix is "revert for now, and we can look at
> this as a cleanup with the cpu0_logical_apicid thing for 5.4 instead".
>
> Hmm?
>
> Linus
next prev parent reply other threads:[~2019-09-09 13:54 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-09-02 17:28 Linux 5.3-rc7 Linus Torvalds
2019-09-07 10:10 ` Chris Wilson
2019-09-07 14:29 ` Thomas Gleixner
2019-09-07 14:41 ` Chris Wilson
2019-09-07 15:00 ` Thomas Gleixner
2019-09-07 15:24 ` Chris Wilson
2019-09-07 20:12 ` Thomas Gleixner
2019-09-07 19:17 ` Linus Torvalds
2019-09-07 19:27 ` Linus Torvalds
2019-09-09 13:54 ` Bandan Das [this message]
2019-09-07 20:44 ` Thomas Gleixner
2019-09-07 21:13 ` Linus Torvalds
2019-09-08 11:02 ` Sasha Levin
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=jpga7bdpoca.fsf@linux.bootlegged.copy \
--to=bsd@redhat.com \
--cc=chris@chris-wilson.co.uk \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=torvalds@linux-foundation.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.