Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2414446ybb; Sat, 21 Mar 2020 22:03:04 -0700 (PDT) X-Google-Smtp-Source: ADFU+vucBnY4VgLUKlExQjQcq60Kn6A7ZiQRdmOxhdKISvEWxuC9WbzzrdbuJlKYPiuEb8axM/XU X-Received: by 2002:aca:d553:: with SMTP id m80mr12795646oig.30.1584853384835; Sat, 21 Mar 2020 22:03:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584853384; cv=none; d=google.com; s=arc-20160816; b=pvLsodSTr6Ogyem/xxdDfpTkhsSpasVedL2FcvtJPqZQ6XmPskfKMeltJ7BgaJnD4O Jaw5ga6PWMNBpGuUx7UW3/1jqWdDJvqbWHifOeVInmFX+P7XFn4Wqh/nK2l3OuqvkpPM DUtnqo3FxWx3FNMJicruDZyU+Sc+ZcmNuO4BukqcMlz53fDi0aoRQZw6kPBb+x9F7IhM iGn+9vd5yi2o/b4tKc6nmHt8GAaHICQoCn/CB0x94ujnW2le7/qF29oIuLnooV5ddDza QtTW+nh5CY1DankP/div8kLcqzJxft3rUc9NCP9+NceiGZNpggsYMWEdiuYITdupZbKB M/zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-id:content-language:accept-language:in-reply-to:references :message-id:date:thread-index:thread-topic:subject:cc:to:from :ironport-sdr:dkim-signature; bh=Akj1/4hZdLgAAocbObXU4fIq1mdgkUYIaID/FqYSWrQ=; b=VbBiEztR6OHLIQn+rqGA7U21OPKTNSgIVwbRWiwNV8XSLGhCXdj69AS+ieMBVbHrnC wOaK+Ae8rOf1i6dRy06tmGcUgTkG/TbhG8xpjd90Ov2gJ8w0ijQPg4HhwLZBPMDVkKy5 /bHXNKVSXWPwujVFDUjOje4Hy2MTSKqM4CHIVWtw3vNJhjCWPs+IQnBsg5wgI3RunIKI OV8dmI/hVp5d5lzZhbp6+seG6eM04X8SS4F2VFzytN5mg/ejVLdc0EEiv4a9L1eH2J/+ n0/bg6A4sOcpJADh4JJyQBzuRhKoFkOJO33ObZOnqwpz8riPLJtcxv9wMHJE2LUrZZRz VztA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=Duj0cfkG; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z126si5806258oia.187.2020.03.21.22.02.37; Sat, 21 Mar 2020 22:03:04 -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=@amazon.com header.s=amazon201209 header.b=Duj0cfkG; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725997AbgCVFCI (ORCPT + 99 others); Sun, 22 Mar 2020 01:02:08 -0400 Received: from smtp-fw-2101.amazon.com ([72.21.196.25]:53690 "EHLO smtp-fw-2101.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725825AbgCVFCI (ORCPT ); Sun, 22 Mar 2020 01:02:08 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1584853326; x=1616389326; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-id:content-transfer-encoding: mime-version; bh=Akj1/4hZdLgAAocbObXU4fIq1mdgkUYIaID/FqYSWrQ=; b=Duj0cfkGc7cuCEzTV5xfkSn7qBMPaUoZZTHf0jLIyWEtdBkwuTuhs5V6 RtfvheO3dwYHrT+WiQ6MULJqpwEGjzgXUQoSTJIaOQDcIGQNXnsmmJZYi hOvjCgGhnRIBMX3NR0WKre7reBl5fTqhpufqw8ZfJba1IfXwX/08IHKbN E=; IronPort-SDR: uH/oNdx9YCVv4TZ1hs8CwxqcbHW/Zgbn7+Z92uRrx0+60XZdd70S6BOw7/wQ0i/CavfLZlfn4U eLb5TnYb0Llg== X-IronPort-AV: E=Sophos;i="5.72,291,1580774400"; d="scan'208";a="22620290" Received: from iad12-co-svc-p1-lb1-vlan2.amazon.com (HELO email-inbound-relay-2b-4e24fd92.us-west-2.amazon.com) ([10.43.8.2]) by smtp-border-fw-out-2101.iad2.amazon.com with ESMTP; 22 Mar 2020 05:01:53 +0000 Received: from EX13MTAUWB001.ant.amazon.com (pdx4-ws-svc-p6-lb7-vlan2.pdx.amazon.com [10.170.41.162]) by email-inbound-relay-2b-4e24fd92.us-west-2.amazon.com (Postfix) with ESMTPS id 8CDF4A22FA; Sun, 22 Mar 2020 05:01:52 +0000 (UTC) Received: from EX13D01UWB002.ant.amazon.com (10.43.161.136) by EX13MTAUWB001.ant.amazon.com (10.43.161.207) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Sun, 22 Mar 2020 05:01:52 +0000 Received: from EX13D21UWB003.ant.amazon.com (10.43.161.212) by EX13d01UWB002.ant.amazon.com (10.43.161.136) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Sun, 22 Mar 2020 05:01:51 +0000 Received: from EX13D21UWB003.ant.amazon.com ([10.43.161.212]) by EX13D21UWB003.ant.amazon.com ([10.43.161.212]) with mapi id 15.00.1497.006; Sun, 22 Mar 2020 05:01:51 +0000 From: "Herrenschmidt, Benjamin" To: "tglx@linutronix.de" , "linux-kernel@vger.kernel.org" , "Singh, Balbir" CC: "keescook@chromium.org" , "x86@kernel.org" Subject: Re: [RFC PATCH] arch/x86: Optionally flush L1D on context switch Thread-Topic: [RFC PATCH] arch/x86: Optionally flush L1D on context switch Thread-Index: AQHWAAb/fhfst31X3kyskBT87ZBwlQ== Date: Sun, 22 Mar 2020 05:01:51 +0000 Message-ID: References: <20200313220415.856-1-sblbir@amazon.com> <87imj19o13.fsf@nanos.tec.linutronix.de> In-Reply-To: <87imj19o13.fsf@nanos.tec.linutronix.de> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-messagesentrepresentingtype: 1 x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.43.161.71] Content-Type: text/plain; charset="utf-8" Content-ID: <996620386F644641B4C1217BEE5C8E3A@amazon.com> Content-Transfer-Encoding: base64 MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org T24gVGh1LCAyMDIwLTAzLTE5IGF0IDAxOjM4ICswMTAwLCBUaG9tYXMgR2xlaXhuZXIgd3JvdGU6 DQo+IEJhbGJpciwNCj4gDQo+IEJhbGJpciBTaW5naCA8c2JsYmlyQGFtYXpvbi5jb20+IHdyaXRl czoNCj4gPiBUaGlzIHBhdGNoIGlzIGFuIFJGQy9Qb0MgdG8gc3RhcnQgdGhlIGRpc2N1c3Npb24g b24gb3B0aW9uYWxseSBmbHVzaGluZw0KPiA+IEwxRCBjYWNoZS4gIFRoZSBnb2FsIGlzIHRvIGFs bG93IHRhc2tzIHRoYXQgYXJlIHBhcmFub2lkIGR1ZSB0byB0aGUgcmVjZW50DQo+ID4gc25vb3Ag YXNzaXN0ZWQgZGF0YSBzYW1wbGluZyB2dWxuZXJhYmlsaXRlcywgdG8gZmx1c2ggdGhlaXIgTDFE IG9uIGJlaW5nDQo+ID4gc3dpdGNoZWQgb3V0LiAgVGhpcyBwcm90ZWN0cyB0aGVpciBkYXRhIGZy b20gYmVpbmcgc25vb3BlZCBvciBsZWFrZWQgdmlhDQo+ID4gc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