From nobody Mon Jun 8 07:26:15 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of seabios.org designates 78.46.105.101 as permitted sender) client-ip=78.46.105.101; envelope-from=seabios-bounces@seabios.org; helo=coreboot.org; Authentication-Results: mx.zohomail.com; spf=pass (zohomail.com: domain of seabios.org designates 78.46.105.101 as permitted sender) smtp.mailfrom=seabios-bounces@seabios.org; dmarc=fail(p=none dis=none) header.from=drv.nu Return-Path: Received: from coreboot.org (mail.coreboot.org [78.46.105.101]) by mx.zohomail.com with SMTPS id 1780454838874822.0674115267518; Tue, 2 Jun 2026 19:47:18 -0700 (PDT) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) by coreboot.org (Postfix) with ESMTPA id D426354E501; Wed, 3 Jun 2026 02:47:14 +0000 (UTC) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) by coreboot.org (Postfix) with ESMTP id D229254E385 for ; Wed, 3 Jun 2026 02:46:32 +0000 (UTC) Received: from authenticated-user (PRIMARY_HOSTNAME [PUBLIC_IP]) [IPv6:2601:647:4800:5ccb:5644:74bc:39bb:11d0]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange x25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) (Authenticated sender: daniel@oak.drv.nu) by oak.drv.nu (Postfix) with ESMTPSA id 1F01A103032; Tue, 02 Jun 2026 19:46:30 -0700 (PDT) From: Daniel Verkamp To: seabios@seabios.org Date: Tue, 2 Jun 2026 19:46:26 -0700 Message-ID: <20260603024626.1419114-1-daniel@drv.nu> MIME-Version: 1.0 X-Spam-Level: * Message-ID-Hash: CHAH2MUBTQXBY4AOJGNUN7LUHQD3FC7V X-Message-ID-Hash: CHAH2MUBTQXBY4AOJGNUN7LUHQD3FC7V X-MailFrom: daniel@drv.nu X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; loop; banned-address; header-match-seabios.seabios.org-0; header-match-seabios.seabios.org-1; emergency; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.11b1 Precedence: list Subject: [SeaBIOS] [PATCH] vbe: fix Set Window return status in linear mode List-Id: SeaBIOS mailing list Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: Content-Transfer-Encoding: quoted-printable Authentication-Results: coreboot.org; auth=pass smtp.auth=mailman@coreboot.org smtp.mailfrom=seabios-bounces@seabios.org X-Spamd-Bar: / X-ZM-MESSAGEID: 1780454839972158500 Content-Type: text/plain; charset="utf-8" VBE function 05h (Display Window Control) is not allowed while a linear framebuffer mode is set. However, the return status code for this case was not fully filled out: only the AH register was filled out, but AL was left unchanged from its original function 05h value, resulting in a status code of 0x0305, whereas the correct status would be 0x034F (indicating that the function is supported but is invalid in the current mode). This may be a result of a too-literal reading of the VBE specification; when describing the behavior of this function when called in a linear mode, it says "the function must fail with completion code AH=3D03h", not mentioning the value of AL. However, the general "VBE Return Status" section still applies, which indicates that AL should be set to 4Fh on return if the function is supported. Additionally, the patch changes the status code assignment to use a hex literal instead of a constant, since this is consistent with all of the other status code assignments in the VBE code. Signed-off-by: Daniel Verkamp --- vgasrc/vbe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vgasrc/vbe.c b/vgasrc/vbe.c index 2ae0a980..67162d97 100644 --- a/vgasrc/vbe.c +++ b/vgasrc/vbe.c @@ -257,7 +257,7 @@ vbe_104f05(struct bregs *regs) if (regs->bh > 1 || regs->bl > 1) goto fail; if (GET_BDA_EXT(vbe_mode) & MF_LINEARFB) { - regs->ah =3D VBE_RETURN_STATUS_INVALID; + regs->ax =3D 0x034f; return; } struct vgamode_s *curmode_g =3D get_current_mode(); --=20 2.54.0 _______________________________________________ SeaBIOS mailing list -- seabios@seabios.org To unsubscribe send an email to seabios-leave@seabios.org