From patchwork Fri Jul 7 13:44:30 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tom Lendacky X-Patchwork-Id: 9830437 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id D1DAE602CA for ; Fri, 7 Jul 2017 13:46:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id C6DB52833E for ; Fri, 7 Jul 2017 13:46:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BA73228504; Fri, 7 Jul 2017 13:46:38 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4A60A2833E for ; Fri, 7 Jul 2017 13:46:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753103AbdGGNop (ORCPT ); Fri, 7 Jul 2017 09:44:45 -0400 Received: from mail-dm3nam03on0069.outbound.protection.outlook.com ([104.47.41.69]:3822 "EHLO NAM03-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752969AbdGGNoi (ORCPT ); Fri, 7 Jul 2017 09:44:38 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=VngOl5Otx4+X/Yzg9FSj/bpI5xBy/MnURtUYCZsmyyw=; b=BpjzwsSMxC1sS7MXD0s6VS3Ao0LJjyqAoxVOPXXoxK72Sd0AJNgI6fEiWRoEHfSefrVw72q0IQtaIXvf3xjanx0bl1PZPUWNmXfov0jK3/tfeiftsvKJJCDJmox2MN4/xA6cbj3rBkFuq6y8SGWSvT/gqKDqOvCrE3+alDy6vOs= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none; vger.kernel.org; dmarc=none action=none header.from=amd.com; Received: from tlendack-t1.amdoffice.net (165.204.77.1) by DM5PR12MB1146.namprd12.prod.outlook.com (10.168.236.141) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1220.11; Fri, 7 Jul 2017 13:44:33 +0000 From: Tom Lendacky Subject: [PATCH v9 34/38] x86/mm: Create native_make_p4d() for PGTABLE_LEVELS <= 4 To: linux-arch@vger.kernel.org, linux-efi@vger.kernel.org, kvm@vger.kernel.org, linux-doc@vger.kernel.org, x86@kernel.org, kexec@lists.infradead.org, linux-kernel@vger.kernel.org, kasan-dev@googlegroups.com, xen-devel@lists.xen.org, linux-mm@kvack.org, iommu@lists.linux-foundation.org Cc: Brijesh Singh , Toshimitsu Kani , Radim =?utf-8?b?S3LEjW3DocWZ?= , Matt Fleming , Alexander Potapenko , "H. Peter Anvin" , Larry Woodman , Jonathan Corbet , Joerg Roedel , "Michael S. Tsirkin" , Ingo Molnar , Andrey Ryabinin , Dave Young , Rik van Riel , Arnd Bergmann , Konrad Rzeszutek Wilk , Borislav Petkov , Andy Lutomirski , Boris Ostrovsky , Dmitry Vyukov , Juergen Gross , Thomas Gleixner , Paolo Bonzini Date: Fri, 07 Jul 2017 08:44:30 -0500 Message-ID: <20170707134430.29711.74599.stgit@tlendack-t1.amdoffice.net> In-Reply-To: <20170707133804.29711.1616.stgit@tlendack-t1.amdoffice.net> References: <20170707133804.29711.1616.stgit@tlendack-t1.amdoffice.net> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: BN6PR03CA0059.namprd03.prod.outlook.com (10.173.137.21) To DM5PR12MB1146.namprd12.prod.outlook.com (10.168.236.141) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 57b25982-93c3-45dd-5000-08d4c53e4e52 X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(48565401081)(300000503095)(300135400095)(201703131423075)(201703031133081)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:DM5PR12MB1146; X-Microsoft-Exchange-Diagnostics: 1; DM5PR12MB1146; 3:4Kixd9V7jvbUZLtQFj2D8nqgM5W/usdA4XmFu0EkFhVwW6MkJEHlbeFMiQtdSov+po/hufy/KMD5QWBQEmumehLN+lfRbxfqXA5tVVSzh2/mW+QAy5Q/lu7DZN4paahb6PkimEQuk41sASjE2BPOeAyuwb22nIS6AGCJUIH/mweT94I8Bwm7RxQMjBaTJsiJUYTFH9DPWzMKish5zbkeFJGzPHlijeDZME6vdUt2lKgcIs3qthmJVkkLiqkTIjUX0+3KyeVeAauWDQODYsobPQz1I3lsuEEQNMkG8tUMt4uje8XWXDhakyQ4Kkfzcavx7Ia8CKrIH3Qxtc2dvXyryYCkShYq/EOrmtXxL1+e4pdduQm0P+Z+NbiBDdTCRkHpakgoKP7eEDXGeu7m3Ln58Pvyy7vjcG+d9x2qmL50aUzoQF6Cb/1puI1ZVFS5X1Mt0PE9Un6zPHkNY8eYn7X+BmU/s0+FCLjIAQw+TQYerT6ZtQS0/ZtpRsv4DUblseobOCbYOZ0zawlE+uVtDiZkLnd1uLGo4lfA4neloMLoI0Dm+QFibc8bG/i9aJMtndqDv8CV5OaApIJbfdOk9Z+jrygMFzqwFZK6pKnSvY3npPr6RQPSMbqz0L+ROUiVIDWz8taxvyeOoxOR2GKaWauZmwSRxjO5n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OdceR85LGh2ZQweHCu/OoBL4djk5kUG9txOsQ5V3jijzYP5A0rqCq4G1jIMNdkpx9NGukQnQLtT3zyiEhO6GET+oXeP6ThjPgDJh1hyCj84ESEkoM6MR6XZhyRfF5+jmtLBHhE8TbDi8XK0PO5O4UDk1D7ajn33NMRn0hcjPdQP0GK7Ry3eXUCYxGorX9yoRA0Rl5sCf4WVNJU5vTwDJZLt8dGZZXlat2CrPWejhqqXHTDsZ85RuxyhDL3xS7i4TFVDF X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(10201501046)(3002001)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6041248)(20161123555025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123562025)(20161123560025)(20161123564025)(20161123558100)(6072148)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DM5PR12MB1146; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DM5PR12MB1146; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtETTVQUjEyTUIxMTQ2OzQ6Nkp0Z3pDSXlGMEd0MVVKdkZXY0FJek5VY1Rt?= =?utf-8?B?V29PeS80QnVhTE5mczV5WTNNTjgvclZSZjluMFNQUTNXc1F5SzZidEhEUGdr?= =?utf-8?B?VFE3b2ozQWpBNXZmZ3Jzd242bWxWYVJZTnBUZTB3MkVad2Jqa0RzWWxLcTJ5?= =?utf-8?B?cFF1cGhYWVc4QkkyV09HUlgwZDJDbzJxU1RRTXJwc0ZycHpFYVA3VndudXNW?= =?utf-8?B?alN2NU9tRU1yZ2F5TXNQeEViaUcvaHVNSkpDbnM1RXV2Y3ZoWGVUWkVkRE5U?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QXJ6cHFsL0JGc3hNLzdnNE9v?= =?utf-8?B?czhMclJOUFFNQzNPWURPUEM0RUVITFpEczlkdlVza2E4YWRveDExRGJwQlNI?= =?utf-8?B?T2o3bXlSMER4d3NyUDFBbXVXZVhtQms0cmdMS3k1b25qTEN2bGYrT0R5bFNL?= =?utf-8?B?cHhBRFE3Mm1qZmFua2JZbXg4aU42TjVGeVFEdG9SRzA3YlZ3TkpOby83MU5j?= =?utf-8?B?aG9vdmk1VkdBdVl4dHFobmxxV2NHWDh4aERPNjcxNExVSkE3NEVzZWFhOVgv?= =?utf-8?B?b3pPcUl1TUU3V1NBL0MzMU5MQ1RnN043QjlIYjlxenFFVEFCMnF2UWdJY3g3?= =?utf-8?B?UUtmV3Z2WVNDSTU0RXNuTk8wM09YdWVwQXg5UURraTVOb0wxTksxUGpWMElT?= =?utf-8?B?SXg3TmF3Y1MrOUFFenBEazA0NXI5UWpNN25iZE42b0NCTG9MdmhlbitINTdt?= =?utf-8?Q?enXHiv12rLIm8+fOoyf?= X-Forefront-PRVS: 0361212EA8 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(39400400002)(39410400002)(39860400002)(39850400002)(39840400002)(39450400003)(2906002)(81166006)(42186005)(83506001)(189998001)(8676002)(38730400002)(305945005)(2950100002)(103116003)(53416004)(4326008)(110136004)(33646002)(25786009)(6506006)(86362001)(53936002)(47776003)(97746001)(50986999)(23676002)(9686003)(66066001)(7736002)(76176999)(72206003)(478600001)(230700001)(6116002)(7406005)(5660300001)(7416002)(50466002)(55016002)(54906002)(1076002)(54356999)(3846002)(921003)(1121003); DIR:OUT; SFP:1101; SCL:1; SRVR:DM5PR12MB1146; H:tlendack-t1.amdoffice.net; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtETTVQUjEyTUIxMTQ2OzIzOnlnb0szWUkyN01pTk9DZFhMWEExb3FsMERJ?= =?utf-8?B?d2JqYVZ3dngreUN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Wq/DAtiQpu6jbqyHAvg0gBKgzCZdLq7nDJGseKax3w8WWYAeXjkOUmEFqf2Kpb6sh91Hq X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 Jul 2017 13:44:33.1891 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR12MB1146 Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Currently, native_make_p4d() is only defined when CONFIG_PGTABLE_LEVELS is greater than 4. Create a macro that will allow for defining and using native_make_p4d() when CONFIG_PGTABLES_LEVELS is not greater than 4. Signed-off-by: Tom Lendacky --- arch/x86/include/asm/pgtable_types.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/arch/x86/include/asm/pgtable_types.h b/arch/x86/include/asm/pgtable_types.h index 830992f..6c55973 100644 --- a/arch/x86/include/asm/pgtable_types.h +++ b/arch/x86/include/asm/pgtable_types.h @@ -309,6 +309,11 @@ static inline p4dval_t native_p4d_val(p4d_t p4d) #else #include +static inline p4d_t native_make_p4d(pudval_t val) +{ + return (p4d_t) { .pgd = native_make_pgd((pgdval_t)val) }; +} + static inline p4dval_t native_p4d_val(p4d_t p4d) { return native_pgd_val(p4d.pgd);