Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2418396ybb; Sat, 21 Mar 2020 22:10:00 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuuiJ1+3f48r/4fCNW3Z1Zgf7WsBJJK0WbwUuXMHkSQmfu9lg59p2mXqKy09oTnTiT4WDOg X-Received: by 2002:a9d:4ee:: with SMTP id 101mr13007895otm.301.1584853800542; Sat, 21 Mar 2020 22:10:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584853800; cv=none; d=google.com; s=arc-20160816; b=P51eG01q7F+zggA6nIksA6Ed7obMbEu7GoxDA0UjDvdQmyQYZ3Wedxuvh0Ctg5AzPl RvYBhMfswL9C/JDnuC8mGAJy4K8UNTXvJLKJUasUwmacaNJRF5UYfQitwq6KaP8MhYGd 7N+jn+c9VJGGC6NdKaWeshZdCvkkYxzzC231VnKps58XJpraG4toJNrZC8SHHlHnnKgd prRwt7G6ZlWHVqxyWIkiTOxfc4npgwapPXHAUHXv7p1KTVG96igDm/ox/iecRFxdY3Uf dCFcc/Csa23gOhT1b6MWLy1tlSuR1elU3DiSzLqPX3GddAPIkP988M06lFNnD6hwK37m eT6A== 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=b00lT/mOaCdiIWpbkqB91fDaLdIPPP2mZJZvNnR7X28=; b=lqemSWE3kl32haAU4giwkf+DrJWGMd/xyCOemYHvORbDVdxfB5BVLbwJ0X4XbJyfgG 7QXdDKV7MH6mwhddaCY48QfeDe9gwE2cUuylXKxMY2DXzl6DQ3xAMy3OwBAdhlYeV63v 6cXkqoqV0DUgYizLPy0CytTZIB3zMrKrxXH5EYj6vE0K8cscQIQxI999W3/mXypCLlIj 6K17XZza4XTYsEBy+f+xztkoquviVVG9C0yv6hO8ouUWyXnzxOOQ+3rm9nO+M8YREK5H rMQnZCqb/5j3mlfpiMvCZpPzK+0JewynO+VSj1v3T1c1v0xyc45k98AzbSiHZBE6JRpD KgUg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=HC1xDNlr; 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 n64si3271266oih.256.2020.03.21.22.09.46; Sat, 21 Mar 2020 22:10:00 -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=HC1xDNlr; 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 S1725987AbgCVFIh (ORCPT + 99 others); Sun, 22 Mar 2020 01:08:37 -0400 Received: from smtp-fw-6001.amazon.com ([52.95.48.154]:17164 "EHLO smtp-fw-6001.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725765AbgCVFIh (ORCPT ); Sun, 22 Mar 2020 01:08:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1584853716; x=1616389716; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-id:content-transfer-encoding: mime-version; bh=b00lT/mOaCdiIWpbkqB91fDaLdIPPP2mZJZvNnR7X28=; b=HC1xDNlr2FU47IkNVo89kZEUx5Xx7RFqLAbiNsAvRq+nXHqgYxXed+PY 9hQE3b+N+2bvkZPITnA5yJleUmcX0wrMVdr024cssDCo6mpf4aqWi59pj wnbNJdUBvvYTswivEfgOZsBeNynyUu3nyBrBjBuK8RkBcE06B8ZLnKx+r c=; IronPort-SDR: Wd3P7IVQDJiCXHfh+KeQJf5RA2cA045m9rVbd8fGdSgKpJzYIvBoe0fXJ5vJpG6/aSxVF/+8sr j/moW2nCioew== X-IronPort-AV: E=Sophos;i="5.72,291,1580774400"; d="scan'208";a="23627141" Received: from iad12-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-1e-97fdccfd.us-east-1.amazon.com) ([10.43.8.6]) by smtp-border-fw-out-6001.iad6.amazon.com with ESMTP; 22 Mar 2020 05:08:24 +0000 Received: from EX13MTAUWB001.ant.amazon.com (iad55-ws-svc-p15-lb9-vlan3.iad.amazon.com [10.40.159.166]) by email-inbound-relay-1e-97fdccfd.us-east-1.amazon.com (Postfix) with ESMTPS id 09685A22D1; Sun, 22 Mar 2020 05:08:21 +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:08:21 +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:08:21 +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:08:21 +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: AQHWAAfn6i+PyJUPFk+FYFtSBQE7cw== Date: Sun, 22 Mar 2020 05:08:20 +0000 Message-ID: <99ef5eec8502a7b53eee362063b9b2252a5a47da.camel@amazon.com> References: <20200313220415.856-1-sblbir@amazon.com> <87imj19o13.fsf@nanos.tec.linutronix.de> <97b2bffc16257e70b8aa98ee86622dc4178154c4.camel@amazon.com> <8736a3456r.fsf@nanos.tec.linutronix.de> In-Reply-To: <8736a3456r.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.160.180] Content-Type: text/plain; charset="utf-8" Content-ID: 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 T24gRnJpLCAyMDIwLTAzLTIwIGF0IDEyOjQ5ICswMTAwLCBUaG9tYXMgR2xlaXhuZXIgd3JvdGU6 DQo+IEJhbGJpciwNCj4gDQo+ICJTaW5naCwgQmFsYmlyIiA8c2JsYmlyQGFtYXpvbi5jb20+IHdy aXRlczoNCj4gPiBPbiBUaHUsIDIwMjAtMDMtMTkgYXQgMDE6MzggKzAxMDAsIFRob21hcyBHbGVp eG5lciB3cm90ZToNCj4gPiA+IFdoYXQncyB0aGUgcG9pbnQ/IFRoZSBhdHRhY2sgc3VyZmFjZSBp cyB0aGUgTDFEIGNvbnRlbnQgb2YgdGhlIHNjaGVkdWxlZA0KPiA+ID4gb3V0IHRhc2suIElmIHRo ZSBtYWxpY2lvdXMgdGFzayBzY2hlZHVsZXMgb3V0LCB0aGVuIHdoeSB3b3VsZCB5b3UgY2FyZT8N Cj4gPiA+IA0KPiA+ID4gSSBtaWdodCBiZSBtaXNzaW5nIHNvbWV0aGluZywgYnV0IEFGQUlD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