Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp6835820ybl; Wed, 15 Jan 2020 10:59:28 -0800 (PST) X-Google-Smtp-Source: APXvYqxcaziZ8iFi9n/9URdVVT5r9jv5mGC+99yD3zCBHBDtmbEWqfKGqDZAmEP1APHmM3vXdNl6 X-Received: by 2002:a9d:4f0a:: with SMTP id d10mr3826045otl.85.1579114767955; Wed, 15 Jan 2020 10:59:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1579114767; cv=none; d=google.com; s=arc-20160816; b=LqAfSmgztzhMRdrVs0CeifklgJ5ncvLuZqjKhrxyuvE6GC8yjb1JCcEJbap0rNOBLn SNWzyx6G5GarWhx0+KBDjV3Q5o/b/s5JMJIWnkMft/0yTHl+2h7hbfz3uzNRxOCEqjgA QGjBz3zy7raKCPdeDMiwPmc6sS6+NEGY+fI+OCNisQy07QLGbSDhq/VHQLkWTkEih+AR DSekCSh+p97LrzLxv0yODlRlwhD3zI0wbdfj1erYWvAYbFXuuWquybMl6Tmg7auea7p3 97iE9GSZmdB/hQoSkgC+6TsTiujQk14WKbDyAJZ3Gdi3Nf7wkZM96O35WCZp49b0iA5R W3+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=viW5lUxcta83gnrt+PjYRxoac+oGqhs+xUeSRvnZmTQ=; b=xxMrQm8LAFxSxf7RL+W5T/CIeLxosMBqxg57WPzKAGm480Ga+OdbmQUgzGDj6TtWSZ TieDSyR6s2KW7NYHCeFv+G8FG2orVaL3Aen13nhtgx63Ka0gTRVThrnIhdipvBppk35G 4pKvJavKPCmGbARJyrM02oUOxU68GPydBAzxiE9wt9KatTE8B/BAElDn2mashPrWOxaw isqKdUTUBnrEZzXTe9ej/cLaUd2KUVtnoIjWtkdh4PyThpWZbLVee3FE1UKs87pvGYBr PpA3R2+NrVkxltD6FVp6RjyT0AavltUwn4+xt2brQQQZpOQSu5HF6+KPRuiHxNV825Rw 52Dw== ARC-Authentication-Results: i=1; mx.google.com; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z62si9930730oiz.271.2020.01.15.10.59.14; Wed, 15 Jan 2020 10:59:27 -0800 (PST) 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; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729021AbgAOS6S (ORCPT + 99 others); Wed, 15 Jan 2020 13:58:18 -0500 Received: from mail-pj1-f67.google.com ([209.85.216.67]:40620 "EHLO mail-pj1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728904AbgAOS6R (ORCPT ); Wed, 15 Jan 2020 13:58:17 -0500 Received: by mail-pj1-f67.google.com with SMTP id bg7so335660pjb.5; Wed, 15 Jan 2020 10:58:17 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=viW5lUxcta83gnrt+PjYRxoac+oGqhs+xUeSRvnZmTQ=; b=CYSt8+RNsbNv8nhdw2VzG2Im59kpDOIKJlD44SJBT+dIJ/uHz2uOIajgLTzBtm/Ggg zvujyncpq9VAS6w4YTBIwx+olglDb4XAhjs2BVUeYhmctnKl36tPa0UabFy0bCWw0JJM 1auljMvtqzovmb0KksdNMNmnEc2CZNzyz5zhGZFuMkCP6s2EqVZUDw7LPBTTO20t2Z1h I4NTVxg35dGwetuVfQxaAZ9JFtgszPLse3P1H6Tyk/HXkeM4vTodCi696JWiSIAnNQA/ IZuhoyYwjCSrazHZfFhYdZT3xQbDD51wE3SLyfeJFAb/iDn3TfNswGAtkb0tyiy86G2r 7pdQ== X-Gm-Message-State: APjAAAX2hMUtwAkQHf8E8Xq13JT17VNqbH383OmOuh4tln77U7lO5/nK IagunJIHGPTCAJHzqTqm/qI= X-Received: by 2002:a17:90a:26ab:: with SMTP id m40mr1624578pje.42.1579114696566; Wed, 15 Jan 2020 10:58:16 -0800 (PST) Received: from 42.do-not-panic.com (42.do-not-panic.com. [157.230.128.187]) by smtp.gmail.com with ESMTPSA id v9sm504680pja.26.2020.01.15.10.58.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 15 Jan 2020 10:58:14 -0800 (PST) Received: by 42.do-not-panic.com (Postfix, from userid 1000) id 7338E40244; Wed, 15 Jan 2020 18:58:12 +0000 (UTC) Date: Wed, 15 Jan 2020 18:58:12 +0000 From: Luis Chamberlain To: Jari Ruusu Cc: Borislav Petkov , Fenghua Yu , Linus Torvalds , johannes.berg@intel.com, linux-kernel@vger.kernel.org, stable@vger.kernel.org, Hans de Goede , Andy Lutomirski Subject: Re: Fix built-in early-load Intel microcode alignment Message-ID: <20200115185812.GH11244@42.do-not-panic.com> References: <20200113154739.GB11244@42.do-not-panic.com> <20200115021545.GD11244@42.do-not-panic.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 15, 2020 at 08:46:04PM +0200, Jari Ruusu wrote: > On 1/15/20, Luis Chamberlain wrote: > > On Mon, Jan 13, 2020 at 09:58:25PM +0200, Jari Ruusu wrote: > >> Before that 16-byte alignment patch was applied, my only one > >> microcode built-in BLOB was "accidentally" 16-byte aligned. > > > > How did it accidentially get 16-byte aligned? > > Old code aligned it to 8-bytes. > There is 50/50-chance of it also being 16-byte aligned. But *how? Why is there a 50/50 chance of it being aligned to 16 bytes if 8 bytes are currently specified? > So it ended up being both 8-byte and 16-byte aligned. What do you mean both? How can it be aligned to both? > > Also, how do you *know* something is broken right now? > > I haven't spotted brokenness in Linux microcode loader other > than that small alignment issue. > > However, I can confirm that there are 2 microcode updates newer > than what my laptop computer's latest BIOS includes. Both newer > ones (20191115 and 20191112) are unstable on my laptop computer > i5-7200U (fam 6 model 142 step 9 pf 0x80). Hard lockups with both > of them. Back to BIOS microcode for now. I was more interested in how you are *certain*, other than manualcode inspection, and that a spec indicates we should use 16 bytes for Intel microcode -- that the 8 byte alignment *does* not allow users to currently update their Intel CPU microcode for built-in firmware. From what I gather so far we have no case yet reported where we know for sure it fails right now with the 8 byte alignment on 64-bit. This information would just be useful for the commit log. Luis