Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp399118pxb; Fri, 22 Apr 2022 03:31:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyvK/b3/Z6accI6ui3KuJQwbEDZWN9/EuZ5vFgAYTZ5Hhvy3MJnrqNE+Xt2aAAa7nr1UwAB X-Received: by 2002:a05:6402:2813:b0:424:1882:d064 with SMTP id h19-20020a056402281300b004241882d064mr4077200ede.357.1650623471882; Fri, 22 Apr 2022 03:31:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1650623471; cv=none; d=google.com; s=arc-20160816; b=G2/ALVQMvEj7xS0dKEbw4OgO48Kx3Fao5/2loPax08QCzdWJ+6a7KCPkhoEAG3kBRz dfPIfOjazpfWuT/yONiQlJHBgdMTzv0XsTpAdRhx/uoMmH3wcDgxKD7YLQmO6uvMtjld lt3v6Tf3chTIJ5LSvXvN0ShRI6JE1esnfseGMtDO4H77lqNwkJbNOV6jP0rvUn/OLlJu TDzQ4TslR+HOp1mg42HbqsywPx99gx9h7AHV/a+n2BYof2cq6v8hCZ0ZlZP573xhaE9L 3LAEBSmljyVCCem6ThhJzpzoO1BHJ3WRZ4Ta7OOsoSyE9/R8razIWxxJDwTE3wtNPrnb 9TBA== 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-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=DzuI/hP4j8qyKw02hy+UWxmxPErK21aY6wcTdlY7vX0=; b=bXYonMf/eajAxA55pTst2EH8vMdL/lNt2tZaLE5veQWHmAoC003F4kmek9ptl5a8Q4 dPkoXDI2Zm/xbL/oNFnbyGePW7NCA2Tc4zmBPo4dz68yHrQuFu3kQ+Ybr2srhY/QKpAo Dt3xdyJY31Ddb6K8zHbZOkhvaaQczcWNqa02yR0Xz7t4apeBK46w/E3pH5C2p3XXRlll /m4SLDaLLRY4oIr6GpsuTYujxCJPNhYamM/DPb7C4yWCYloJpng173DdTWma1mMXrfX7 V+EjB3DJ6iKMj040+RVstiE5B2ulPpwn8Xy6+1wMTOuo4UWkeVCeoiEjgqMB6FN1UiCv 2VcA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=dYA53jEa; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id m14-20020a056402510e00b0042197a5622fsi6337119edd.521.2022.04.22.03.30.47; Fri, 22 Apr 2022 03:31:11 -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=@infradead.org header.s=desiato.20200630 header.b=dYA53jEa; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1349773AbiDSMD1 (ORCPT + 99 others); Tue, 19 Apr 2022 08:03:27 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50078 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244321AbiDSMBZ (ORCPT ); Tue, 19 Apr 2022 08:01:25 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 438481FA67 for ; Tue, 19 Apr 2022 04:57:58 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Transfer-Encoding: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Sender:Reply-To:Content-ID:Content-Description; bh=DzuI/hP4j8qyKw02hy+UWxmxPErK21aY6wcTdlY7vX0=; b=dYA53jEasPAswBQt9fprgbs7Q6 Pr1tFn/7z5/Q1Q901av7xURJmYYp5Es4BaV7Tcnowc/kX8mmc9S/NdwlGtjcY2YiDE4G3LKanvS7B wLmYO1TIUFsmwKEkKVmsT7awSo0MtIWQjX7HIWu6S+CQA08Ml2uaPmxr427ZgqeqEFrBfHJj+W2BT mLDfsoN5tsUe63kLOA1Lzd1OZZElV4ku6xScEaEkuO37s/wLg/9JM8/4yKcJRyqzClDJ9qvaqsYD3 632Ihd6pLS0RdjcDGfgjOomBVlV/cEtKR31yUOp33Gy9tC6QvzejJUyooy4b/muCHrqjRaLywR+X1 LhcoX+qw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1ngmUF-006oN1-7J; Tue, 19 Apr 2022 11:57:39 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id A3E4B986195; Tue, 19 Apr 2022 13:57:37 +0200 (CEST) Date: Tue, 19 Apr 2022 13:57:37 +0200 From: Peter Zijlstra To: Andrew Cooper Cc: Josh Poimboeuf , "x86@kernel.org" , "linux-kernel@vger.kernel.org" , Miroslav Benes , Boris Ostrovsky , Juergen Gross , Stefano Stabellini , "xen-devel@lists.xenproject.org" Subject: Re: [PATCH v2 06/25] x86/xen: Add ANNOTATE_ENDBR to startup_xen() Message-ID: <20220419115737.GU2731@worktop.programming.kicks-ass.net> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: 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_NONE,T_SCC_BODY_TEXT_LINE 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: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Apr 19, 2022 at 11:42:12AM +0000, Andrew Cooper wrote: > On 18/04/2022 17:50, Josh Poimboeuf wrote: > > The startup_xen() kernel entry point is referenced by the ".note.Xen" > > section, but is presumably not indirect-branched to. > > It's the real entrypoint of the VM.? It's "got to" by setting %rip > during vcpu setup. > > We could in principle support starting a PV VM with CET active, but that > sounds like an enormous quantity of effort for very little gain.? CET > for Xen PV requires paravirt anyway (because the kernel runs in CPL!=0) > so decisions like this can wait until someone feels like doing the work. > > > Add ANNOTATE_ENDBR > > to silence future objtool warnings. > > > > Cc: Boris Ostrovsky > > Cc: Juergen Gross > > Cc: Stefano Stabellini > > Cc: xen-devel@lists.xenproject.org > > Signed-off-by: Josh Poimboeuf > > FWIW, Reviewed-by: Andrew Cooper , preferably > with the commit message tweaked to remove the uncertainty. Something like so then? --- Subject: x86/xen: Add ANNOTATE_ENDBR to startup_xen() From: Josh Poimboeuf Date: Mon, 18 Apr 2022 09:50:25 -0700 From: Josh Poimboeuf The startup_xen() kernel entry point is referenced by the ".note.Xen" section, and is the real entry point of the VM. It *will* be indirectly branched to, *however* currently Xen doesn't support PV VM with CET active. Add ANNOTATE_ENDBR to silence future objtool warnings. Fixes: ed53a0d97192 ("x86/alternative: Use .ibt_endbr_seal to seal indirect calls") Signed-off-by: Josh Poimboeuf Signed-off-by: Peter Zijlstra (Intel) Reviewed-by: Andrew Cooper Link: https://lkml.kernel.org/r/a87bd48b06d11ec4b98122a429e71e489b4e48c3.1650300597.git.jpoimboe@redhat.com