From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E4867606A322 for ; Thu, 3 Dec 2026 00:15:13 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.a=rsa-sha256 header.s=k20260515 header.b=RtHBWUjU Received: from list by lists.xenproject.org with outflank-mailman.1511282.1703736 (Exim 4.92) (envelope-from ) id 1xYuTU-0000aU-8b; Thu, 03 Dec 2026 00:15:00 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 1511282.1703736; Thu, 03 Dec 2026 00:15:00 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xYuTU-0000aN-4w; Thu, 03 Dec 2026 00:15:00 +0000 Received: by outflank-mailman (input) for mailman id 1511282; Thu, 03 Dec 2026 00:14:59 +0000 Received: from mx.expurgate.net ([195.190.135.20]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1xYuTT-0000aH-BI for xen-devel@lists.xenproject.org; Thu, 03 Dec 2026 00:14:59 +0000 Received: from mx.expurgate.net (helo=localhost) by mx.expurgate.net with esmtp id 1xYuTS-0001de-A5 for xen-devel@lists.xenproject.org; Thu, 03 Dec 2026 01:14:58 +0100 Received: from [10.42.69.3] (helo=localhost) by localhost with ESMTP (eXpurgate MTA 0.9.1) (envelope-from ) id 6b10b467-bab6-0a2a0a5309dd-0a2a4503ec24-24 for ; Thu, 03 Dec 2026 01:14:58 +0100 Received: from [172.105.4.254] (helo=tor.source.kernel.org) by tlsNG-33051d.mxtls.expurgate.net with ESMTPS (eXpurgate 4.57.1) (envelope-from ) id 6b10b481-fae8-0a2a45030019-ac6904fec5ac-3 for ; Thu, 03 Dec 2026 01:14:58 +0100 Received: from smtp.kernel.org (quasi.space.kernel.org [100.103.45.18]) by tor.source.kernel.org (Postfix) with ESMTP id 9E9D660CE9; Thu, 3 Dec 2026 00:14:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C71EC1F00893; Thu, 3 Dec 2026 00:14:54 +0000 (UTC) X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Post: List-Help: List-Subscribe: , Precedence: list Sender: "Xen-devel" Authentication-Results: eu.smtp.expurgate.cloud; dkim=pass header.s=k20260515 header.d=kernel.org header.i="@kernel.org" header.h="Date:From:To:cc:Subject:In-Reply-To:References" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1796256896; bh=01d5UfEh1ZyMNfNugEjcp/wa7xeEkR62tIEjXe8ztSk=; h=Date:From:To:cc:Subject:In-Reply-To:References; b=RtHBWUjUSgBFu3x+jvKF89JiYUXgRskojCcW+rIcxDJ27yJ4gx8EOzd1XeB+mCIbm FYs1Z7CdNuhvNqTvCWFDqHOKIMohKQg3pQP0H5zAZ5BCxHLoUtis1zTANWTWxfxpZZ xJ4dT9GjTe7tLc98fMEqFI/P5Upbu7xVtzfeOPEpi++/ONoTJwnkoXQ64apC/6nIfp GTZPCd2zMxwYZMY1dLLJDJpTUT+MoXf4EPSZWw8w6pzawNuoXdH9wV8vRAtAV8hdJK lcuEKXI0/9XATO8gakOzmFYYte5yP8w8FDikqxQyFBKfNPA1HF8VQkeRC3zSUOOlQp egLXD4z+0qLYQ== Date: Wed, 2 Dec 2026 16:14:53 -0800 (PST) From: Stefano Stabellini To: Denis Mukhin cc: xen-devel@lists.xenproject.org, andrew.cooper3@citrix.com, anthony.perard@vates.tech, jbeulich@suse.com, julien@xen.org, michal.orzel@amd.com, roger@xenproject.org, sstabellini@kernel.org, dmukhin@xen.org Subject: Re: [XTF PATCH v1 4/6] x86: skip registering unavailable Xen console In-Reply-To: <20261111195109.1070169-5-dmukhin@ford.com> Message-ID: References: <20261111195109.1070169-1-dmukhin@ford.com> <20261111195109.1070169-5-dmukhin@ford.com> X-Archived-By: MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII X-purgate-ID: tlsNG-33051d/1796256898-6FEC24E9-D2FEB494/0/0 X-purgate-type: clean X-purgate-size: 2046 X-Spam-Status: No, score=-15.8 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI,SPF_HELO_PASS, SPF_PASS,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 On Wed, 11 Nov 2026, dmukhin@ford.com wrote: > From: Denis Mukhin > > Do not register Xen console for the test in case HYPERCALL_console_io > is not available. > > Signed-off-by: Denis Mukhin Reviewed-by: Stefano Stabellini > --- > arch/x86/setup.c | 5 +++-- > include/xtf/hypercall.h | 4 ++-- > 2 files changed, 5 insertions(+), 4 deletions(-) > > diff --git a/arch/x86/setup.c b/arch/x86/setup.c > index 8fea6495de1c..725abe289a05 100644 > --- a/arch/x86/setup.c > +++ b/arch/x86/setup.c > @@ -250,7 +250,7 @@ static void qemu_console_write(const char *buf, size_t len) > > static void xen_console_write(const char *buf, size_t len) > { > - hypercall_console_write(buf, len); > + (void)hypercall_console_write(buf, len); > } > > /* > @@ -297,7 +297,8 @@ void arch_setup(void) > if ( IS_DEFINED(CONFIG_HVM) && !pvh_start_info ) > register_console_callback(qemu_console_write); > > - register_console_callback(xen_console_write); > + if ( !hypercall_console_write("\0", 1) ) > + register_console_callback(xen_console_write); > > collect_cpuid(IS_DEFINED(CONFIG_PV) ? pv_cpuid_count : cpuid_count); > > diff --git a/include/xtf/hypercall.h b/include/xtf/hypercall.h > index 68b3da111d85..475eb771d472 100644 > --- a/include/xtf/hypercall.h > +++ b/include/xtf/hypercall.h > @@ -194,9 +194,9 @@ static inline long hypercall_argo_op(unsigned int cmd, void *arg1, void *arg2, > /* > * Higher level hypercall helpers > */ > -static inline void hypercall_console_write(const char *buf, unsigned long count) > +static inline long hypercall_console_write(const char *buf, unsigned long count) > { > - (void)HYPERCALL3(long, __HYPERVISOR_console_io, CONSOLEIO_write, count, buf); > + return HYPERCALL3(long, __HYPERVISOR_console_io, CONSOLEIO_write, count, buf); > } > > static inline long hypercall_shutdown(unsigned int reason) > -- > 2.56.0 >