From patchwork Tue Mar 28 20:17:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Borislav Petkov X-Patchwork-Id: 7362 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2482263vqo; Tue, 28 Mar 2023 13:21:21 -0700 (PDT) X-Google-Smtp-Source: AKy350ZLZ8BiumiKr1NtGRqzcX6NTEvVl8ea+VTZbh+eTZBVWFAT/VfI4rT1yGyULiIhBw5DxadC X-Received: by 2002:a17:906:32d8:b0:946:e68f:402c with SMTP id k24-20020a17090632d800b00946e68f402cmr157708ejk.9.1680034881238; Tue, 28 Mar 2023 13:21:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680034881; cv=none; d=google.com; s=arc-20160816; b=plmkmBra+6DOFFFKXFFjXYSHHMn/4TuaxH8MR2X+FmSyLLHqJlH3+AWTKdHf4WIDca 8QuROwiisoCxi6P1OpqGdmaKwI3NxchUA/t1ksxcmtZ5xZMws+AvQ34gH/v3jqIP3FH7 Vs/QVGs5GTskyCd5IWoMuvAcUCll91Q4JH2sw5uHgqM9D8+L3UoshdqOmawON7Oe6WZW Mgh920nLCyH/v53viUgdAeSvC0GZf44g3yLd+8jPlSOJgN+XecX/j4i6kwicRz+8WOlI T6ZjwStpCcB1/i6p6dNaCFf2suZSs4ESKvI5v5Y+GvU9JFnctxeK+U6YM15WpHNFYBY0 RBQw== 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=kFsCdhfkmyUE8dh7nh5WbRx/wlVVqOjTxXee2PAdFbg=; b=h9k1q924rnRZ0bPjDI1eCG6JTn87wpeMKTNsEGUTw5jT8cvSm+zLGZ9/ReSWVoWCCz wxh/pSt66Yo2TkEtyXTF9C8sm7QMfITpfXpKJ8uX+qshKPa4wzU1XF1CYcF2wEQ5qdfS 8ne60qaBaaQGmyK5SLC7pT3fZTtfzlU4t0NOqSoLju2ukQXMizUgqkuuJ6z7Kklmdknw Zy1k5kjelPYZSHZOFlSoHwjsBB1nDODsBGTxuO2hUo+Z1P+TMYHgff/pN28GkIP/ojmE vm5pl2o9cmdUyaDt2/jbvMix82A9PSKzJB1cjUidd0uLclEYk9+0fNH/xByE4okoQC8D O0jA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=FdF+186Y; 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=NONE sp=NONE dis=NONE) header.from=alien8.de Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id bk17-20020a170906b0d100b008e7916f1952si30951754ejb.822.2023.03.28.13.20.57; Tue, 28 Mar 2023 13:21:21 -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=@alien8.de header.s=dkim header.b=FdF+186Y; 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=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229904AbjC1URt (ORCPT + 99 others); Tue, 28 Mar 2023 16:17:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34298 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229772AbjC1URo (ORCPT ); Tue, 28 Mar 2023 16:17:44 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A833144A7 for ; Tue, 28 Mar 2023 13:17:15 -0700 (PDT) Received: from zn.tnic (p5de8e687.dip0.t-ipconnect.de [93.232.230.135]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 89F7C1EC0338; Tue, 28 Mar 2023 22:17:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1680034633; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type: content-transfer-encoding:content-transfer-encoding:in-reply-to: references; bh=kFsCdhfkmyUE8dh7nh5WbRx/wlVVqOjTxXee2PAdFbg=; b=FdF+186YrHjVu3ePm9jtyPXYlfhvUxb9NJmmildi12nK5FMk2xZKhBizN+BdswpJesq9sg nK96OAbvT/WfeRyNtACv91lEZ3ZBiJYe8wn+3nqoTrePxuRl530lHDcL3yAIdxyd4yGVH8 9cQPHfeSS9A/MurkOl0gDDi8ovRtlzw= From: Borislav Petkov To: Joerg Roedel , Tom Lendacky Cc: X86 ML , LKML Subject: [PATCH v2 0/2] SEV-*: Cleanups Date: Tue, 28 Mar 2023 22:17:10 +0200 Message-Id: <20230328201712.25852-1-bp@alien8.de> X-Mailer: git-send-email 2.35.1 MIME-Version: 1.0 X-Spam-Status: No, score=-0.2 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1761644255894923135?= X-GMAIL-MSGID: =?utf-8?q?1761644255894923135?= From: "Borislav Petkov (AMD)" Hi, here's v2. tglx says it is better for cc_platform_has() and descendants to be noinstr vs inlining it as the whole code is a bit bigger for that. I've queued the export of cc_vendor already so that the parallel CPU bringup stuff can use it: https://git.kernel.org/tip/5ae57743f578725a5dadb6f31d7798ee55e6e967 Thx. Borislav Petkov (AMD) (2): x86/coco: Mark cc_platform_has() and descendants noinstr x86/sev: Get rid of special sev_es_enable_key arch/x86/coco/core.c | 8 ++++---- arch/x86/include/asm/sev.h | 11 +++++++---- arch/x86/kernel/sev.c | 5 ----- 3 files changed, 11 insertions(+), 13 deletions(-) Acked-by: Tom Lendacky