From nobody Sat May 23 21:00:42 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=invisiblethingslab.com ARC-Seal: i=1; a=rsa-sha256; t=1779196093; cv=none; d=zohomail.com; s=zohoarc; b=F8L5B5/9vpY0A8xyYaSNyjL/72YCz0+5cthakXEcUhoB9ZSX9JAi7hu4XBrRAInNesoGzHaPB+z9/M0qMltdjZKKWeRxAE/g6XuKSEeXZ1eb5gWQaj/cIezdACPyLhP98NwJwoT7RZr2dmrccRmYqS6CASsqaQm+buJlaHB1m6U= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1779196093; h=Content-Type:Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=1GCvfVbmC+gEyoOjFaasIPFibJzKYv/qS1gecQDz3pk=; b=PxCcjPzlmsypRNl0at+zE90WY0qxdN1d17iJ06ot+Ov4ZcXQH4cvQSJFrqXdxETKTk3byc/JEDZIHgJQlsjfpvVMXLpVnM8WyUZlFdEt0HVvxG2iRD7nzGuSZ+x94Ja9bMEMdmMIoFPtnqBTxIwmubgD8/rf1om2LXFrotw3b4Q= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1779196093301179.26155145097323; Tue, 19 May 2026 06:08:13 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.1312991.1583141 (Exim 4.92) (envelope-from ) id 1wPKAh-0001lU-PX; Tue, 19 May 2026 13:07:43 +0000 Received: by outflank-mailman (output) from mailman id 1312991.1583141; Tue, 19 May 2026 13:07:43 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1wPKAh-0001lN-Lr; Tue, 19 May 2026 13:07:43 +0000 Received: by outflank-mailman (input) for mailman id 1312991; Tue, 19 May 2026 13:07:41 +0000 Received: from mx.expurgate.net ([195.190.135.10]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1wPKAf-0001ix-R7 for xen-devel@lists.xenproject.org; Tue, 19 May 2026 13:07:41 +0000 Received: from mx.expurgate.net (helo=localhost) by mx.expurgate.net with esmtp id 1wPKAf-009WyO-1A for xen-devel@lists.xenproject.org; Tue, 19 May 2026 15:07:41 +0200 Received: from [10.42.69.9] (helo=localhost) by localhost with ESMTP (eXpurgate MTA 0.9.1) (envelope-from ) id 6a0c6095-bab6-0a2a0a5309dd-0a2a4509b0e4-16 for ; Tue, 19 May 2026 15:07:40 +0200 Received: from [103.168.172.159] (helo=fhigh-a8-smtp.messagingengine.com) by tlsNG-bad1c0.mxtls.expurgate.net with ESMTPS (eXpurgate 4.56.1) (envelope-from ) id 6a0c609b-2497-0a2a45090019-67a8ac9f83c9-3 for ; Tue, 19 May 2026 15:07:40 +0200 Received: from phl-compute-07.internal (phl-compute-07.internal [10.202.2.47]) by mailfhigh.phl.internal (Postfix) with ESMTP id 43E03140005B; Tue, 19 May 2026 09:07:39 -0400 (EDT) Received: from phl-frontend-04 ([10.202.2.163]) by phl-compute-07.internal (MEProxy); Tue, 19 May 2026 09:07:39 -0400 Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 19 May 2026 09:07:37 -0400 (EDT) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" Authentication-Results: eu.smtp.expurgate.cloud; dkim=pass header.s=fm3 header.d=invisiblethingslab.com header.i="@invisiblethingslab.com" header.h="Cc:Content-Transfer-Encoding:Content-Type:Date:From:Message-ID:MIME-Version:Subject:To"; dkim=pass header.s=fm3 header.d=messagingengine.com header.i="@messagingengine.com" header.h="Cc:Content-Transfer-Encoding:Content-Type:Date:Feedback-ID:From:Message-ID:MIME-Version:Subject:To:X-ME-Proxy:X-ME-Sender" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= invisiblethingslab.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:from:from:in-reply-to :message-id:mime-version:reply-to:subject:subject:to:to; s=fm3; t=1779196059; x=1779282459; bh=1GCvfVbmC+gEyoOjFaasIPFibJzKYv/q S1gecQDz3pk=; b=SRB8rkPJRZ4UXCPRkaLtoaZPfihaib9lpwHK2eo410d4LmxE y8jmi+kiwN7fNHOq/2MLe8RUAVKd77irQfHDoKMPysJtnQw4QtDSaMfxsxyWITQJ BRY/NCARBvKg/4Zk7iCzLCBiyZWIl2rC7UuLz0yFDg1KOkUvyVO2phdS8STpdIJ+ iUxN4FAoUeLzN35m2oLPbib2UwtmyZgUVD531dVxfc4ddSKR6Z65dh3Ha7ZZ35IH 6fNHN1y198LGNDKnMNQykPcNWIJFOTGpAOlg7D+jFSSqDmaU/m3JVtLnRX8KUZx5 fUbWVyOYhiV4LmxachrFJBWd2/J68GQ2jKktcw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:message-id:mime-version:reply-to:subject :subject:to:to:x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s= fm3; t=1779196059; x=1779282459; bh=1GCvfVbmC+gEyoOjFaasIPFibJzK Yv/qS1gecQDz3pk=; b=QJCW1XRSzhFvgYe6fKCIix72Yuokvp4s6BW/FGQZ2gTX heOg3NQ2E93HbQyY2G9F8Ot4Wdj6mWcjaVdn+DCdNBCr1me77QviMRx8yGbo1gRe YcfFkvfi/u/A5fowpNVA/ChtaeS4/uYQEu5mGaxXprj1J0NkkhkVHjQKvg9T7DPi jgH01YWrEDsiVnYFSPfjpoDNhoZCakzkTo9ZF3qZWNU9qG5/vhug/AMD8XTarTTA kLCpPNukhMBkQnDKKPxm/TbxTYRl6vCxAWEPEUDe56Vq8sSyG+OraaSrQ0bCUh7O lVZmRMaw/ykA2s5xIrQKO8MIyyhIi66eMrw3geB+fw== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeefhedrtddtgddugedukeefucetufdoteggodetrf dotffvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfurfetoffkrfgpnffqhgenuceu rghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmnecujf gurhephffvvefufffkofggtgfgsehtkeertdertdejnecuhfhrohhmpefuiiihmhhonhcu tegtvggurgnkshhkihcuoegrtggtvghksehinhhvihhsihgslhgvthhhihhnghhslhgrsg drtghomheqnecuggftrfgrthhtvghrnhepiefffffhgfetheelledtudffleetteehfeek geeltdeuhfehleelhfejffdvueelnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrg hmpehmrghilhhfrhhomheprggttggvkhesihhnvhhishhisghlvghthhhinhhgshhlrggs rdgtohhmpdhnsggprhgtphhtthhopeehpdhmohguvgepshhmthhpohhuthdprhgtphhtth hopeigvghnqdguvghvvghlsehlihhsthhsrdigvghnphhrohhjvggtthdrohhrghdprhgt phhtthhopegrtggtvghksehinhhvihhsihgslhgvthhhihhnghhslhgrsgdrtghomhdprh gtphhtthhopeguphhsmhhithhhsegrphgvrhhtuhhsshholhhuthhiohhnshdrtghomhdp rhgtphhtthhopehmrghrmhgrrhgvkhesihhnvhhishhisghlvghthhhinhhgshhlrggsrd gtohhmpdhrtghpthhtohepjhgsvghulhhitghhsehsuhhsvgdrtghomh X-ME-Proxy: Feedback-ID: i792e4853:Fastmail From: =?UTF-8?q?Szymon=20Aceda=C5=84ski?= To: xen-devel@lists.xenproject.org Cc: =?UTF-8?q?Szymon=20Aceda=C5=84ski?= , "Daniel P. Smith" , =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= , Jan Beulich Subject: [PATCH for-4.22] EFI: Fix boot from a device without a file system Date: Tue, 19 May 2026 15:06:57 +0200 Message-ID: <5ee376dc0df448437f386ab2606c42d63a515ca1.1779194154.git.accek@invisiblethingslab.com> X-Mailer: git-send-email 2.53.0 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-purgate-ID: tlsNG-bad1c0/1779196060-88D76A53-0AE0874E/0/0 X-purgate-type: clean X-purgate-size: 1737 X-ZohoMail-DKIM: pass (identity @invisiblethingslab.com) X-ZM-MESSAGEID: 1779196095328158500 When netbooting a unified Xen kernel image (via GRUB chainloader), the resulting loaded_image->DeviceHandle does not support SIMPLE_FILE_SYSTEM_PROTOCOL. Instead of crashing via noreturn PrintErrMesg(), print a message via PrintStr() and return NULL from get_parent_handle(). Signed-off-by: Szymon Aceda=C5=84ski Acked-by: Marek Marczykowski-G=C3=B3recki --- Tested on Intel Lunar Lake laptop via PXE-loaded GRUB chainloading the unified image including Xen built from upstream staging. Without the patch the boot aborts with: Couldn't obtain the File System Protocol Interface: ErrCode: 0x8000000000= 000003 (EFI_UNSUPPORTED, per UEFI spec Appendix D). With the patch, dom0 reaches login. xen/common/efi/boot.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/xen/common/efi/boot.c b/xen/common/efi/boot.c index 9ea2183c0b..a6c3c371c6 100644 --- a/xen/common/efi/boot.c +++ b/xen/common/efi/boot.c @@ -471,6 +471,15 @@ static EFI_FILE_HANDLE __init get_parent_handle(const = EFI_LOADED_IMAGE *loaded_i /* Get the file system interface. */ ret =3D efi_bs->HandleProtocol(loaded_image->DeviceHandle, &fs_protocol, (void **)&fio); + if ( ret =3D=3D EFI_UNSUPPORTED ) + { + /* + * The image could come from a device without a file system, + * for example it could be a netbooted unified Xen kernel imag= e. + */ + PrintStr(L"File System Protocol not supported on boot device\r= \n"); + return NULL; + } if ( EFI_ERROR(ret) ) PrintErrMesg(L"Couldn't obtain the File System Protocol Interf= ace", ret); --=20 2.53.0