Message ID | 20221103113636.25543-1-jgross@suse.com |
---|---|
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp477674wru; Thu, 3 Nov 2022 04:51:10 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4W8flEk9B5OG4Ifq6FvbmIXq/PKm0yu35ogHOBj2kNiJyXzuFc8g+cMQiCMK8NUBVd08Yt X-Received: by 2002:a17:902:ec8e:b0:186:f4ba:a7fc with SMTP id x14-20020a170902ec8e00b00186f4baa7fcmr29680101plg.55.1667476269725; Thu, 03 Nov 2022 04:51:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1667476269; cv=none; d=google.com; s=arc-20160816; b=F9Bgs4Sv3o0GVQxisNqcDMx4OTg4FJMyW/TMp67N5NKUe+aq/wnAtASrPBRZS2RlvM klDTdHUjyJQWtIKMcLE3rTXSCLISDCfj62/aVRREfNoGiFmd6tQWhGTSdnHx9U6vzHxF UUGVFu12h/RmenuvIqs+HPv0zncQR6PpzcLH7qU3pOX6jijJmISFzxBdHIeRYZnGdQYQ ghNj9Jbu0Yb6B1uwcQaV10H1BNEK40KZs2jnDXroGUZXQpZdXCEcfAinO5fkp0708vu0 X2SIDDP4bwH41Ce1CB7NvGlVF6vvV5GGSHkE6pPflUAdlnsQcPp5QE9+ovy1ZImfORNC QdMg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=R2jqME7F+qdUftTzWR72PDDjTzwv0qCQjs1xhw+ZdsU=; b=wyUfFm9bFhD3wgTozKPDrpMPot8p3LunnWZhN0MgfsdVMPb8nCh5aYn1WiAbnjOB5Y PAqV+xitgrz+spYohkrHPcsjxka3UfwdH2hdQo3pluEPyydLnrHZBMuWM4lEqfPea5O5 RZp5g/EqdRDsfF0nGGiXPxYa1dEips1UdIBxo/pez9zYW2szhGHmLNKKWccdwud6ETuj oM7HrEnxb4snrBacvAJoH3iWRLyTWIynZsXWgYQOmqbHQUnGmjizTGdWUNteIlBZ6SMz RkOizl6tJ87JRW8y2ZZfPeINSn4mUVyHEx9Wxsc6BgljHF/6QubKiqHv+EC2SoGoF8Zo Bcag== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=lMyg6ETc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h3-20020a17090a648300b00213393ff173si943806pjj.75.2022.11.03.04.50.54; Thu, 03 Nov 2022 04:51:09 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.com header.s=susede1 header.b=lMyg6ETc; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=suse.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230489AbiKCLgy (ORCPT <rfc822;yves.mi.zy@gmail.com> + 99 others); Thu, 3 Nov 2022 07:36:54 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49398 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231151AbiKCLgu (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Thu, 3 Nov 2022 07:36:50 -0400 Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 89A8C6401 for <linux-kernel@vger.kernel.org>; Thu, 3 Nov 2022 04:36:46 -0700 (PDT) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out2.suse.de (Postfix) with ESMTPS id 0B6971F88C; Thu, 3 Nov 2022 11:36:45 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1667475405; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=R2jqME7F+qdUftTzWR72PDDjTzwv0qCQjs1xhw+ZdsU=; b=lMyg6ETc97azzoW47K210vpzsQEyM8fTV4c+5WVVzcj+0lcLDHxabMpcsuQMWDFQvtAZN4 0hHPII4l8tRuDyGpgjP5TscidSmhQjiCJvhdysgX8my9WIWoEW2vGXjt+IpIi1/24B0r9O Dk7aO6PBwgzOCy9oygMAKvYkeLf/lvk= Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id A806913480; Thu, 3 Nov 2022 11:36:44 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id zT6jJ8ynY2PoHgAAMHmgww (envelope-from <jgross@suse.com>); Thu, 03 Nov 2022 11:36:44 +0000 From: Juergen Gross <jgross@suse.com> To: linux-kernel@vger.kernel.org, xen-devel@lists.xenproject.org, x86@kernel.org Cc: Juergen Gross <jgross@suse.com>, Thomas Gleixner <tglx@linutronix.de>, Ingo Molnar <mingo@redhat.com>, Borislav Petkov <bp@alien8.de>, Dave Hansen <dave.hansen@linux.intel.com>, "H. Peter Anvin" <hpa@zytor.com>, Pu Wen <puwen@hygon.cn>, Andy Lutomirski <luto@kernel.org>, Peter Zijlstra <peterz@infradead.org> Subject: [PATCH 0/4] Switch X86_FEATURE_XENPV to cpu_feature_enabled() use Date: Thu, 3 Nov 2022 12:36:32 +0100 Message-Id: <20221103113636.25543-1-jgross@suse.com> X-Mailer: git-send-email 2.35.3 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_MED,SPF_HELO_NONE, SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1748475597286120937?= X-GMAIL-MSGID: =?utf-8?q?1748475597286120937?= |
Series |
Switch X86_FEATURE_XENPV to cpu_feature_enabled() use
|
|
Message
Juergen Gross
Nov. 3, 2022, 11:36 a.m. UTC
Make especially kernels without CONFIG_XEN_PV more efficient by using cpu_feature_enabled(X86_FEATURE_XENPV) instead of boot_cpu_has() and friends. Juergen Gross (4): x86: add X86_FEATURE_XENPV to disabled-features.h x86: remove unneeded 64-bit dependency in arch_enter_from_user_mode() x86: drop 32-bit Xen PV guest code in update_task_stack() x86: switch to cpu_feature_enabled() for X86_FEATURE_XENPV arch/x86/include/asm/disabled-features.h | 8 +++++++- arch/x86/include/asm/entry-common.h | 4 ++-- arch/x86/include/asm/switch_to.h | 7 ++----- arch/x86/kernel/cpu/amd.c | 2 +- arch/x86/kernel/cpu/bugs.c | 2 +- arch/x86/kernel/cpu/hygon.c | 2 +- arch/x86/kernel/process_64.c | 4 ++-- arch/x86/kernel/topology.c | 2 +- arch/x86/mm/cpu_entry_area.c | 2 +- 9 files changed, 18 insertions(+), 15 deletions(-)