Received: by 2002:a25:c593:0:0:0:0:0 with SMTP id v141csp3035346ybe; Sun, 8 Sep 2019 05:54:12 -0700 (PDT) X-Google-Smtp-Source: APXvYqwt8TnsLcnqwWkrVGmK4/wvteTba/M2kJg7xTZdmM6UCrQrbcsfgmVYteSO8yUd+HjyyIxe X-Received: by 2002:a05:6402:3ca:: with SMTP id t10mr19344096edw.271.1567947252880; Sun, 08 Sep 2019 05:54:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567947252; cv=none; d=google.com; s=arc-20160816; b=c4l/HJ1cPu7vhFTlk/v2wOnILAadRdS+zqQm76boNbaqJ2OwbUsMoUcIXLJw9USM6m wdyPpO9uVljkf0P/VSX6o7xGD2lXszQRlYMNqG9oysVaOT3WDZIlRHEcIqpRJ8QG8pKL d6Jfu+fLVA+1I/Bu0z0Yx3uwOeBPxrHVCVbEVxkaEN8BpcdIiBDN2wn18gEORERJ26bS uDHy8XUJ1APHF5UlZLkCa1Gwv8wKa905IrZztzFxJl+ITF4ggRmMEAVAee1lNial84pS 4nGXgEq6nrjXoLxDiVy1wEKWQWdkO+d+5RhRlBEP03G67UemSO2xDdfWtweb6eHa3qNW cGVA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=XwVbZgJQjdxitsafoMUeKLcgUzEgG9R7QqVMwklal/s=; b=dpJgthoLnEsUL6gQ8I3E7RrdFEPT6Vj1PvzqXllazDwCJBr9uxS0Aihgn7ixKF7qMI 0oCh3iBg/gp8Y5blW4j+REpiGOKN+/Od0qhcb3HkH3QCrewMLs8Xn7+QgwIsRJF7ztN4 PeFWjuvdYnn3cgxy4RMjPqvIim7f0/fBEiJkXtmDt12vVJc+XcMHg45iiQPUFP+CVytv Dls09HU527QPUeJhPAXsqlwcjV4UpqLmFRV/rX9DwB+8p5ClbDA8Il+KZ5fWbMYwRxmC azRVkgnQzR/9MF2YQzyXo9spBqAXoJezNu8eeNR8I77r/yPfP1lI4Vxe+ihwe/KYKGQd UerA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=h72a+hFu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s14si2832774edr.139.2019.09.08.05.53.49; Sun, 08 Sep 2019 05:54:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=h72a+hFu; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727099AbfIGTSO (ORCPT + 99 others); Sat, 7 Sep 2019 15:18:14 -0400 Received: from mail-lf1-f65.google.com ([209.85.167.65]:35483 "EHLO mail-lf1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727012AbfIGTSO (ORCPT ); Sat, 7 Sep 2019 15:18:14 -0400 Received: by mail-lf1-f65.google.com with SMTP id w6so7603792lfl.2 for ; Sat, 07 Sep 2019 12:18:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=XwVbZgJQjdxitsafoMUeKLcgUzEgG9R7QqVMwklal/s=; b=h72a+hFu/Zrtkr7IEOdoaFQVcAKgITVe4PwvPJrxmJNE0AHbgKbD9XjdcwnwjJAucH 6BbnZQ/rTq8tDmpU7xCayzD/IZRN/j3J6NKokW/Y1049M+5VDRh0TebNf+ecwWON1Zne nWiWEyrt0FdOpg7OY9f91xiqkONTjPW6jhtsg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=XwVbZgJQjdxitsafoMUeKLcgUzEgG9R7QqVMwklal/s=; b=DcVtRG/us4Zhf/xhnocSky+sBm1YPHbUcIoVl3+LAelbc796BB1t2UozL520ZhmrOQ Pu7xjHkQXyqoqxo45xf/5DQus6YxASzZiw3dzlMOaJrt1JCkxktqTngbohMEYPZrg9FR zDTK5Q2FZjagI/bOcS97t8f/5I7+w2pfh5NAeaC0F13Twabx5lUpi1L0/GFE79bycGhd d7z8tvBMYhRmlFDgfKjVxCizuuIx72LoFg8H+7U5IICBNZFBt28iVvcLMQGy2Kif8Abn ShgsCkrH3acBH4xDToO/ejEesuRQG9oIpy08yGlZgQobE1fPB4uQE29Ihksb6bdo2PlX T00w== X-Gm-Message-State: APjAAAVWExGX7lveQLMF+fuRDiWlYWUH4jEzQhG38hkpQVCfnbbCJSEM adZ80feBAMHw7RGmM6XeKQqncZoSGHQ= X-Received: by 2002:a19:3f47:: with SMTP id m68mr10564190lfa.108.1567883891663; Sat, 07 Sep 2019 12:18:11 -0700 (PDT) Received: from mail-lf1-f44.google.com (mail-lf1-f44.google.com. [209.85.167.44]) by smtp.gmail.com with ESMTPSA id h19sm275667ljj.19.2019.09.07.12.18.10 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Sat, 07 Sep 2019 12:18:10 -0700 (PDT) Received: by mail-lf1-f44.google.com with SMTP id q27so7557539lfo.10 for ; Sat, 07 Sep 2019 12:18:10 -0700 (PDT) X-Received: by 2002:ac2:5c11:: with SMTP id r17mr10932128lfp.61.1567883889956; Sat, 07 Sep 2019 12:18:09 -0700 (PDT) MIME-Version: 1.0 References: <156785100521.13300.14461504732265570003@skylake-alporthouse-com> <156786727951.13300.15226856788926071603@skylake-alporthouse-com> In-Reply-To: From: Linus Torvalds Date: Sat, 7 Sep 2019 12:17:54 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: Linux 5.3-rc7 To: Thomas Gleixner Cc: Chris Wilson , Linux List Kernel Mailing , Bandan Das Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Sep 7, 2019 at 8:00 AM Thomas Gleixner wrote: > > Ok let me find a testbox to figure out whats wrong there. Honestly, it looks like we should just revert that commit, since we never used to clear the LDR bits before either, and the bug it "fixes" doesn't really seem to be a bug (well, it's a bug in KVM, but that's a different thing). And I wouldn't be at all surprised if it confuses some BIOS code. We use the LDR bits ourselves in smp_get_logical_apicid(), and so clearing them out seems entirely bogus. At a guess, it's wakeup_cpu_via_init_nmi() that does that if (apic->dest_logical == APIC_DEST_LOGICAL) id = cpu0_logical_apicid; else id = apicid; and now that we've cleared the APIC LDR bits, we no longer wake the BSP. We send the NMI to the _old_ APIC ID, but we've overwritten it with 0 when we put it to sleep, so now nothing happens. 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? Linus