Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp1095563ybz; Fri, 17 Apr 2020 16:00:22 -0700 (PDT) X-Google-Smtp-Source: APiQypJF8ljaPxAWN/N4aZC2PQgO5Yc5erItzHJ6hkzFBLPfrizjYtv7iqdGNsqqF/15vvuLIqTD X-Received: by 2002:a17:906:1ccb:: with SMTP id i11mr5246714ejh.101.1587164422396; Fri, 17 Apr 2020 16:00:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1587164422; cv=none; d=google.com; s=arc-20160816; b=jJSGda2G/+JAkAPKOZmi4aFovWOCjNe6Ra/IYhhahwESsN2PFZhDmABFARVSYqsJWX BxajxwTLdgMWOG7D3JwgjnbMRBHnn91TnZOsMOC+LdovXINGajrbvL/dauJEdDwqURvs qET9C0J0swgEfKW+TYDby+wUK0mF9u9nvLn7+jjF7B4ybVUq4ue5DmsduC4aPzoOBx4U cznk9ta/4OFDZZMKKl+vXZ12xuinvoKhY4okENCSCohgkAjfimDZWlvx4W4DsCRZ4Lwv wYrHk85JOzQyQQar6aYSiiQ26xcg3XhFydYtKCJSK7ioFdfmn7mDmpbOtuJV8zHCgzxa hqEA== 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=Qp67AI0Sv/1C+D0VIma7kToD5Gl30fiIpHeu/2TOwzo=; b=e6ztjtanY4a2d53EOmnZqjd7+FQ7IBsKqyk9ESpqwHvj8kzFSs6I3vxARhhSjefIB7 lW3hXyBrE+whTIRcfI57rnKDAL4ITCRsVvdr2jPO4A/UudzYBPzoyjgj3nwjflc3zLgL Sr+ILsay/busBVctuxWAW3ZCokQsQbceck2VH9g/bpVyzGrQ7Z2ijyOIqdFuq5aFyc4s MzvxTMzY65/5ggwX35a+4DruiHhGG1sHHPlpB4HrHlasOQQvoDbula6rem81WPtwxUG1 /5Os3Z8zXoI3rPhvcauMZsBewxgpneu131f7u9PSg8PN5v9DY4jhQrs2x2/w8DnjqS70 CSnw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=wCAKWkkL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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. [23.128.96.18]) by mx.google.com with ESMTP id rl12si5245197ejb.199.2020.04.17.15.59.57; Fri, 17 Apr 2020 16:00:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=wCAKWkkL; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 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 S1726036AbgDQW7C (ORCPT + 99 others); Fri, 17 Apr 2020 18:59:02 -0400 Received: from smtp-fw-6001.amazon.com ([52.95.48.154]:33677 "EHLO smtp-fw-6001.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725849AbgDQW7C (ORCPT ); Fri, 17 Apr 2020 18:59:02 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1587164341; x=1618700341; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-id:content-transfer-encoding: mime-version; bh=Qp67AI0Sv/1C+D0VIma7kToD5Gl30fiIpHeu/2TOwzo=; b=wCAKWkkL1EffV5sB9BNJeHYBdnpqn9l45yvlqGKZDXh5PAf8p6iM2sse 9jHxxyGHcPVHekGkampvuiVvmbzd2yZe/YGx/KlVX3IBFazgAsUp75geU xNvV71rOqY6iR5Nb2nUN2vbI54sCqqY36mYYEOAYWOqxKnRgM7NFLQoXC g=; IronPort-SDR: oBvkBR7ILXH9wznF0ANioJnD5bLWC200b/qIjTPhlyjftdpF71OBWSQmHQm8eEvADLkalLw+am /nC3IyZTSCdQ== X-IronPort-AV: E=Sophos;i="5.72,395,1580774400"; d="scan'208";a="27477401" Received: from iad12-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-1d-f273de60.us-east-1.amazon.com) ([10.43.8.6]) by smtp-border-fw-out-6001.iad6.amazon.com with ESMTP; 17 Apr 2020 22:58:48 +0000 Received: from EX13MTAUWB001.ant.amazon.com (iad55-ws-svc-p15-lb9-vlan2.iad.amazon.com [10.40.159.162]) by email-inbound-relay-1d-f273de60.us-east-1.amazon.com (Postfix) with ESMTPS id C564AA2443; Fri, 17 Apr 2020 22:58:45 +0000 (UTC) Received: from EX13D01UWB004.ant.amazon.com (10.43.161.157) by EX13MTAUWB001.ant.amazon.com (10.43.161.249) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 17 Apr 2020 22:58:45 +0000 Received: from EX13D01UWB002.ant.amazon.com (10.43.161.136) by EX13d01UWB004.ant.amazon.com (10.43.161.157) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 17 Apr 2020 22:58:44 +0000 Received: from EX13D01UWB002.ant.amazon.com ([10.43.161.136]) by EX13d01UWB002.ant.amazon.com ([10.43.161.136]) with mapi id 15.00.1497.006; Fri, 17 Apr 2020 22:58:44 +0000 From: "Singh, Balbir" To: "tglx@linutronix.de" , "linux-kernel@vger.kernel.org" CC: "keescook@chromium.org" , "tony.luck@intel.com" , "benh@kernel.crashing.org" , "jpoimboe@redhat.com" , "x86@kernel.org" , "dave.hansen@intel.com" Subject: Re: [PATCH v3 2/5] arch/x86: Refactor tlbflush and l1d flush Thread-Topic: [PATCH v3 2/5] arch/x86: Refactor tlbflush and l1d flush Thread-Index: AQHWFQu/E74C3HKXpEGOWXqP1jJSaw== Date: Fri, 17 Apr 2020 22:58:44 +0000 Message-ID: References: <20200408090229.16467-1-sblbir@amazon.com> <20200408090229.16467-3-sblbir@amazon.com> <87y2qul0wx.fsf@nanos.tec.linutronix.de> In-Reply-To: <87y2qul0wx.fsf@nanos.tec.linutronix.de> Accept-Language: en-GB, 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.203] Content-Type: text/plain; charset="utf-8" Content-ID: <56253E9FA22F9B4A806C9717A7560861@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 T24gRnJpLCAyMDIwLTA0LTE3IGF0IDE1OjAzICswMjAwLCBUaG9tYXMgR2xlaXhuZXIgd3JvdGU6 DQo+IA0KPiBCYWxiaXIgU2luZ2ggPHNibGJpckBhbWF6b24uY29tPiB3cml0ZXM6DQo+ID4gK3Zv aWQgcG9wdWxhdGVfdGxiX3dpdGhfZmx1c2hfcGFnZXModm9pZCAqbDFkX2ZsdXNoX3BhZ2VzKTsN Cj4gPiArdm9pZCBmbHVzaF9sMWRfY2FjaGVfc3codm9pZCAqbDFkX2ZsdXNoX3BhZ2VzKTsNCj4g PiAraW50IGZsdXNoX2wxZF9jYWNoZV9odyh2b2lkKTsNCj4gDQo+IGwxZF9mbHVzaF9wb3B1bGF0 ZV9wYWdlcygpOw0KPiBsMWRfZmx1c2hfc3coKQ0KPiBsMWRfZmx1c2hfaHcoKQ0KPiANCj4gSG1t Pw0KPiANCg0KSSBjYW4gcmVuYW1lIHRoZW0NCg0KPiA+ICt2b2lkIHBvcHVsYXRlX3RsYl93aXRo X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tICAgICAgICAgICAgIHdybXNybChNU1JfSUEzMl9GTFVT SF9DTUQsIEwxRF9GTFVTSCk7DQo+ID4gKyAgICAgaWYgKGZsdXNoX2wxZF9jYWNoZV9odygpID09 IDApDQo+ID4gICAgICAgICAgICAgICByZXR1cm47DQo+ID4gLSAgICAgfQ0KPiANCj4gICAgICAg ICBpZiAoIWwxZF9mbHVzaF9odygpKQ0KPiAgICAgICAgICAgICAgICAgcmV0dXJuOw0KPiANCj4g PiAtICAgICBhc20gdm9sYXRpbGUoDQo+ID4gLSAgICAgICAgICAgICAvKiBGaXJzdCBlbnN1cmUg dGhlIHBhZ2VzIGFyZSBpbiB0aGUgVExCICovDQo+ID4gLSAgICAgICAgICAgICAieG9ybCAgICUl ZWF4LCAlJWVheFxuIg0KPiA+IC0gICAgICAgICAgICAgIi5McG9wdWxhdGVfdGxiOlxuXHQiDQo+ ID4gLSAgICAgICAgICAgICAibW92emJsICglW2ZsdXNoX3BhZ2VzXSwgJSUiIF9BU01fQVggIiks ICUlZWN4XG5cdCINCj4gPiAtICAgICAgICAgICAgICJhZGRsICAgJDQwOTYsICUlZWF4XG5cdCIN Cj4gPiAtICAgICAgICAgICAgICJjbXBsICAgJSVlYXgsICVbc2l6ZV1cblx0Ig0KPiA+IC0gICAg ICAgICAgICAgImpuZSAgICAuTHBvcHVsYXRlX3RsYlxuXHQiDQo+ID4gLSAgICAgICAgICAgICAi eG9ybCAgICUlZWF4LCAlJWVheFxuXHQiDQo+ID4gLSAgICAgICAgICAgICAiY3B1aWRcblx0Ig0K PiA+IC0gICAgICAgICAgICAgLyogTm93IGZpbGwgdGhlIGNhY2hlICovDQo+ID4gLSAgICAgICAg ICAgICAieG9ybCAgICUlZWF4LCAlJWVheFxuIg0KPiA+IC0gICAgICAgICAgICAgIi5MZmlsbF9j YWNoZTpcbiINCj4gPiAtICAgICAgICAgICAgICJtb3Z6YmwgKCVbZmx1c2hfcGFnZXNdLCAlJSIg X0FTTV9BWCAiKSwgJSVlY3hc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