Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp7333617rwl; Thu, 23 Mar 2023 02:56:42 -0700 (PDT) X-Google-Smtp-Source: AK7set+bbdU/Ixnfpd1JMky+cIqWA118qDE9woHyu18rKZvguqUpnKx/OpCeHY9CQH5QL7RbahVR X-Received: by 2002:a17:907:7ea1:b0:92f:ab75:1605 with SMTP id qb33-20020a1709077ea100b0092fab751605mr10891792ejc.73.1679565402378; Thu, 23 Mar 2023 02:56:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1679565402; cv=none; d=google.com; s=arc-20160816; b=cM2Btu2Ahf8Y2j0k2AdFVmvdMIWcsBdpd0y992b3zB1AdocmFFCbEkSjgQGdy+mY0C OLZ91uLJRWSTWCw8AdyZuZDpfoOoqQMge/9GQC1fBQczPOU6So0C1ZeX/VKAiHIuBS4s uL0ZI2Lm4yh3cO2cyqoROoOraUc+Wgo6lV0qa5O8QMbk68WriLHvTVifVuWbppafDHj/ IWVZBZAwZK5OXfvASRlZrUhyBF7NCum9POu0FdZinIjUluDcodp7bPNu+dkBs0QFbslU uS+lb8MVU/z5l5C0i0MvuXWROrPdFLPzAme20QlNnoWNsOfT3wMeyWWYKPvGo+5DP0lp aCqA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=nHvjhzemG6XYPr52d6/om67Svr/zToy+fgDpNSjq//Q=; b=bMF+sdk0F0ITpqINeONgEoMzcdD7+dU14rpq80ozF9iUmInGU0n8+44E+TRVxfdCVF TUjmE5EVvhkEtjAyIqN4K9vE25hc3c08d6Ms7WpUy4G+kciKK+smXJlBLWPJAX6euITh 2Ff33/ZiFXKPsSScJs6LsmaxjslInf2Z8ZEP1rvxwvESOaI4V3xGtjdKfUvAnlZhtNOt XXsfTBJCrH2tQngUcwkBf9yOxXFWxJ47uzm/UusnBLT11DOThN9Uh9sxOf+AAUaQrznK HlE1CSV4eMcMMbEw/0dBTf0iRWtB2g9ihRP2AWWacNDWDKjJ9SwQy/xT0wwh1pvJrNeZ 0XiQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=HyBg9zOE; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id h23-20020a170906261700b0092beae94d7dsi15289717ejc.67.2023.03.23.02.56.18; Thu, 23 Mar 2023 02:56:42 -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=HyBg9zOE; 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 S230283AbjCWJ4A (ORCPT + 99 others); Thu, 23 Mar 2023 05:56:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52156 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230009AbjCWJz2 (ORCPT ); Thu, 23 Mar 2023 05:55:28 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1E10D36080 for ; Thu, 23 Mar 2023 02:54:05 -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 D87591EC0716; Thu, 23 Mar 2023 10:54:02 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1679565242; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=nHvjhzemG6XYPr52d6/om67Svr/zToy+fgDpNSjq//Q=; b=HyBg9zOEjyRPNIX4IDYkkz8U9Uqm3OkEnh1HbvKml0hH7xS2+Fs8VJrc194iJTs0pDrNVN hLhJPhPdz+5GAmwVWyUESftcmOg3ae5pxGEJ/JtbMytCdGoZI5ocblJ61mc+nGOJVTfoZr z9SAOmmGiYqafFynAgHYW7oXkop0TuI= Date: Thu, 23 Mar 2023 10:53:58 +0100 From: Borislav Petkov To: Thomas Gleixner Cc: Joerg Roedel , Tom Lendacky , X86 ML , LKML Subject: Re: [PATCH 2/2] x86/sev: Get rid of special sev_es_enable_key Message-ID: <20230323095358.GBZBwhthMrWyqP4yXH@fat_crate.local> References: <20230318115634.9392-1-bp@alien8.de> <20230318115634.9392-3-bp@alien8.de> <87edpf9690.ffs@tglx> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <87edpf9690.ffs@tglx> 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 On Thu, Mar 23, 2023 at 10:17:15AM +0100, Thomas Gleixner wrote: > That's not sufficient. This function invokes static functions which the > compiler can rightfully put out of line resulting in a noinstr violation. Right, as mentioned on IRC, if we're going to use the cc_platform_has() thing to do simple arch-agnostic confidential guests checks, perhaps we should make it and the underlying functions it calls simply __always_inline so that the compiler can optimize stuff even more and not have function calls for such simple tests... -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette