Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp6829015yba; Wed, 1 May 2019 22:04:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqz7dt+SPGtdM3oJjD+SKhL/rwPNWY3GaoQzycZn5S9RY6rPflkHHfYjFZveq4Vjm7P6rrCx X-Received: by 2002:a63:4f41:: with SMTP id p1mr1827023pgl.63.1556773497212; Wed, 01 May 2019 22:04:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556773497; cv=none; d=google.com; s=arc-20160816; b=iqXomVWAQ7tVGEjEmPOnSm/Sni1esLZOzk2Q2rWP48TvrGcBKC37xH3Q+d6XJCSlip ySnAUrjLEdWSE8Vg2mBkm7efhTFTLibTpJ/2TsWovBr+bzQJ2FEv7jdiDmCEZVJPvFqj 0C6qKllztWCo1fHmDZwzTa2jZSRvop7/AweLN/uMzwiKMzYGp8LQzJS58cBeeI2ycmQb J3qsqR2+jTnvofPaIpqT47+ydNV/JuHdHwlYgqT02m7tCDkSVAlTAIeagwi1dFWl5wrL 8CS0fpx34uBVrpn4BXVHS/N+l8+a48d4ZGZ0hewSZzVRtHdFpwUtFRrfuq5Xzf/TdWvs tvTQ== 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 :wdcipoutbound:content-language:accept-language:in-reply-to :references:message-id:date:thread-index:thread-topic:subject:cc:to :from:dkim-signature:dkim-signature; bh=R2kn8Hnf+2huJg5eK64kcJ1VLqW+CKWjBk7vutYyrAM=; b=UxtLMTo3uc+LAW7J3MuqErTLrXsjtYjhgKHYn3zT2bSBFnkbBllHOovWK5gDmGdIWG UbcCZaNLrXvwx85brhX7NZ3VN9j4JE9LSZ7chOrV/uMGpF6kZhxxp+Fnxw8W7m5rydmZ HWjkuCIY6Px9wOndjiWwBywiTrVvYDzGM5I0kajy6OGscgwHgTqQUwE6B6328CiYizai K0br43k2xErmLww3eacM6NTHsLqpsy8mGtCowRYq3YcyMWpLM1Vk6MdSYGub8bb3Yevb qmdnp9XPGH4UloEat9qms/sd2vq4ua2y2UdVLHa7LigiG314NzKZEe5GJ33JzWWa0IUt VvKg== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=UGMfjE4I; dkim=pass header.i=@sharedspace.onmicrosoft.com header.s=selector1-wdc-com header.b=Dtrp7XP5; 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=wdc.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d124si28358967pfc.114.2019.05.01.22.04.41; Wed, 01 May 2019 22:04:57 -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=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=UGMfjE4I; dkim=pass header.i=@sharedspace.onmicrosoft.com header.s=selector1-wdc-com header.b=Dtrp7XP5; 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=wdc.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726276AbfEBFCn (ORCPT + 99 others); Thu, 2 May 2019 01:02:43 -0400 Received: from esa4.hgst.iphmx.com ([216.71.154.42]:47504 "EHLO esa4.hgst.iphmx.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725616AbfEBFCm (ORCPT ); Thu, 2 May 2019 01:02:42 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1556773362; x=1588309362; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=R2kn8Hnf+2huJg5eK64kcJ1VLqW+CKWjBk7vutYyrAM=; b=UGMfjE4IBAM539GHlFQJe8PNh+AzO7ZT9XKI+8VO+gQ7fypwyFo9CAtI DbSpETwWgYr4ZRfc1YytE0Z7fMao3D4GDxD3Yuw9nLBliM/bepIlgsNrl fyn/BHk5elhpXlo8x5RcnLoGzfsYFnYvZkIin80qFGOOKWDbLHvmP2atI lyiOseRMoM1cD6VhRaOa7MisrVReVAkErc6QRdNzt9gq7rBK0efu6Bf1L 7eGsD6lS5DSAImF58nrEYURrqVfGRni4i21VH2uYdHF8eZzLaRh19sqmH WdvLEOA41Dq+DRMtbweqVBbrZGyzut32kN2z1I9oAn1nQiK7OBLL4LAWq g==; X-IronPort-AV: E=Sophos;i="5.60,420,1549900800"; d="scan'208";a="107321542" Received: from mail-bn3nam04lp2053.outbound.protection.outlook.com (HELO NAM04-BN3-obe.outbound.protection.outlook.com) ([104.47.46.53]) by ob1.hgst.iphmx.com with ESMTP; 02 May 2019 13:02:41 +0800 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sharedspace.onmicrosoft.com; s=selector1-wdc-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=R2kn8Hnf+2huJg5eK64kcJ1VLqW+CKWjBk7vutYyrAM=; b=Dtrp7XP5jlYPP4hw2sNbP5cV2VSDUt635njmDKxejKAXXOf3MmRu1t1iMMTKp2WEGwK4dsF0QJZVDdK0f1wb8hfrAN8WtwWAD7vUnp1ENmBjWqeHXOSXtBRCyHrNJjLg9Vj9vxknTEQv34EO8qu5LdLZgr53/memzUdKp5cXsJ4= Received: from MN2PR04MB6061.namprd04.prod.outlook.com (20.178.246.15) by MN2PR04MB5582.namprd04.prod.outlook.com (20.178.248.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1856.11; Thu, 2 May 2019 05:02:39 +0000 Received: from MN2PR04MB6061.namprd04.prod.outlook.com ([fe80::c500:5fd2:9194:e38]) by MN2PR04MB6061.namprd04.prod.outlook.com ([fe80::c500:5fd2:9194:e38%3]) with mapi id 15.20.1835.015; Thu, 2 May 2019 05:02:39 +0000 From: Anup Patel To: Palmer Dabbelt , Albert Ou CC: Atish Patra , Christoph Hellwig , Paul Walmsley , Mike Rapoport , "linux-riscv@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Anup Patel Subject: [PATCH v4 2/2] RISC-V: Setup initial page tables in two stages Thread-Topic: [PATCH v4 2/2] RISC-V: Setup initial page tables in two stages Thread-Index: AQHVAKRDJGtbwJU08UqZEJU5BFR/cQ== Date: Thu, 2 May 2019 05:02:38 +0000 Message-ID: <20190502050206.23373-3-anup.patel@wdc.com> References: <20190502050206.23373-1-anup.patel@wdc.com> In-Reply-To: <20190502050206.23373-1-anup.patel@wdc.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: BYAPR07CA0049.namprd07.prod.outlook.com (2603:10b6:a03:60::26) To MN2PR04MB6061.namprd04.prod.outlook.com (2603:10b6:208:d8::15) authentication-results: spf=none (sender IP is ) smtp.mailfrom=Anup.Patel@wdc.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.17.1 x-originating-ip: [129.253.179.161] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 3e497745-df5c-4622-fb8b-08d6cebb65da x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600141)(711020)(4605104)(4618075)(2017052603328)(7193020);SRVR:MN2PR04MB5582; x-ms-traffictypediagnostic: MN2PR04MB5582: wdcipoutbound: EOP-TRUE x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:7219; x-forefront-prvs: 0025434D2D x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(366004)(136003)(376002)(39860400002)(396003)(346002)(189003)(199004)(5660300002)(1076003)(6436002)(486006)(305945005)(66066001)(476003)(71200400001)(71190400001)(26005)(44832011)(81156014)(86362001)(81166006)(8676002)(11346002)(102836004)(54906003)(446003)(30864003)(2171002)(25786009)(186003)(110136005)(316002)(6486002)(386003)(14444005)(50226002)(72206003)(6506007)(8936002)(53936002)(256004)(73956011)(36756003)(53946003)(76176011)(3846002)(6116002)(2906002)(4326008)(68736007)(2616005)(66946007)(99286004)(7736002)(14454004)(6512007)(478600001)(66446008)(64756008)(66556008)(66476007)(52116002)(2004002);DIR:OUT;SFP:1102;SCL:1;SRVR:MN2PR04MB5582;H:MN2PR04MB6061.namprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: lgO/GKn8Sr+DJMNMf3tR7j9AyD9CgtchYrR5/bL3t7uyhDKo+cijz//vbtn9UUycBRi06HVTgm4do4F4AHFZAC65BAt2gwO0ABJVVfe9UySNs4aesjmInuN/PHo8TDxNwgvVJbx1II4HOnqU5fZ4ZTuoyOjVb6Pe1nIJuxJEkSjZ5itCoHvHT2dUsgz3f4NasF02XC0Yk7WBqkVeYSWnG4hkxXTg45/fBBQIPllWnxTENnL3bp7eBWmMDHP4SqcqEy+PRyrm6Mu0Qhsh37qezDE4h79JZ0lhzSxXtajTyjHrIPi30GaAA+aF/+G8dbmVa4tigcwRKnkrX4+D/mplBsC7ACKLq2xSvXU9CRrlC6y3pRTSswVCLkS5XmrVyDXclnuESy0TqzmiTB/EbSSg94VX/RpwmffzFtscpfFKYCc= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: wdc.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3e497745-df5c-4622-fb8b-08d6cebb65da X-MS-Exchange-CrossTenant-originalarrivaltime: 02 May 2019 05:02:38.8774 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: b61c8803-16f3-4c35-9b17-6f65f441df86 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR04MB5582 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Q3VycmVudGx5LCB0aGUgc2V0dXBfdm0oKSBkb2VzIGluaXRpYWwgcGFnZSB0YWJsZSBzZXR1cCBp biBvbmUtc2hvdA0KdmVyeSBlYXJseSBiZWZvcmUgZW5hYmxpbmcgTU1VLiBEdWUgdG8gdGhpcywg dGhlIHNldHVwX3ZtKCkgaGFzIHRvIG1hcA0KYWxsIHBvc3NpYmxlIGtlcm5lbCB2aXJ0dWFsIGFk ZHJlc3NlcyBzaW5jZSBpdCBkb2VzIG5vdCBrbm93IHNpemUgYW5kDQpsb2NhdGlvbiBvZiBSQU0u IFRoaXMgbWVhbnMgd2UgaGF2ZSBrZXJuZWwgbWFwcGluZ3MgZm9yIG5vbi1leGlzdGVudA0KUkFN IGFuZCBhbnkgYnVnZ3kgZHJpdmVyIChvciBrZXJuZWwpIGNvZGUgZG9pbmcgb3V0LW9mLWJvdW5k IGFjY2Vzcw0KdG8gUkFNIHdpbGwgbm90IGZhdWx0IGFuZCBjYXVzZSB1bmRlcnRlcm1pbmlzdGlj IGJlaGF2aW91ci4NCg0KRnVydGhlciwgdGhlIHNldHVwX3ZtKCkgY3JlYXRlcyBQTUQgbWFwcGlu Z3MgKGkuZS4gMk0gbWFwcGluZ3MpIGZvcg0KUlY2NCBzeXN0ZW1zLiBUaGlzIG1lYW5zIGZvciBQ QUdFX09GRlNFVD0weGZmZmZmZmUwMDAwMDAwMDAgKGkuZS4NCk1BWFBIWVNNRU1fMTI4R0I9eSks IHRoZSBzZXR1cF92bSgpIHdpbGwgcmVx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