From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from aserp2130.oracle.com ([141.146.126.79]) by Galois.linutronix.de with esmtps (TLS1.2:RSA_AES_256_CBC_SHA256:256) (Exim 4.80) (envelope-from ) id 1fJfqc-000235-PY for speck@linutronix.de; Fri, 18 May 2018 15:55:07 +0200 Received: from pps.filterd (aserp2130.oracle.com [127.0.0.1]) by aserp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w4IDrGTW090395 for ; Fri, 18 May 2018 13:54:59 GMT Received: from aserv0022.oracle.com (aserv0022.oracle.com [141.146.126.234]) by aserp2130.oracle.com with ESMTP id 2hxpvd463t-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 18 May 2018 13:54:59 +0000 Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by aserv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w4IDswUI031610 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 18 May 2018 13:54:59 GMT Received: from abhmp0015.oracle.com (abhmp0015.oracle.com [141.146.116.21]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w4IDswYX013338 for ; Fri, 18 May 2018 13:54:58 GMT Date: Fri, 18 May 2018 09:54:57 -0400 From: Konrad Rzeszutek Wilk Subject: [MODERATED] Is: Sleep states ?Was:Re: SSB status - V18 pushed out Message-ID: <20180518135457.GB18423@char.us.oracle.com> References: MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit To: speck@linutronix.de List-ID: On Thu, May 17, 2018 at 10:53:28PM +0200, speck for Thomas Gleixner wrote: > Folks, > > we finally reached a stable state with the SSB patches. I've updated all 3 > branches master/linux-4.16.y/linux-4.14.y in the repo and attached the > resulting git bundles. They merge cleanly on top of the current HEADs of > the relevant trees. > > The lot survived light testing on my side and it would be great if everyone > involved could expose it to their test scenarios. > > Thanks to everyone who participated in that effort (patches, review, > testing ...)! Yeey! Thank you. I was reading the updated Intel doc today (instead of skim reading it) and it mentioned: "Intel recommends that the SSBD MSR bit be cleared when in a sleep state on such processors." We don't seem to be doing that? To do that we would need to: 1) Revert 4b59bdb56945 x86/bugs: Remove x86_spec_ctrl_set() 2) Peppering if (static_cpu_has(X86_FEATURE_SPEC_STORE_BYPASS_DISABLE)) x86_spec_ctrl_set(~SPEC_CTRL_SSBD); [when enterring sleep state] and: if (static_cpu_has(X86_FEATURE_SPEC_STORE_BYPASS_DISABLE)) x86_spec_ctrl_set(SPEC_CTRL_SSBD); [when coming out] in mwait_idle_with_hints, mwait_idle, and native_play_dead Or alternatively fiddle with the MSR directly. 3) And then uhuh, I am not sure how you would want to deal when the applications are running. That is when the !static_cpu_has(X86_FEATURE_SPEC_STORE_BYPASS_DISABLE) but still want the MSR toggled. > > Thanks, > > tglx