From nobody Sat May 10 10:00:47 2025 Delivered-To: importer@patchew.org Received-SPF: none (zoho.com: 80.81.252.135 is neither permitted nor denied by domain of seabios.org) client-ip=80.81.252.135; envelope-from=seabios-bounces@seabios.org; helo=mail.coreboot.org; Authentication-Results: mx.zohomail.com; spf=none (zoho.com: 80.81.252.135 is neither permitted nor denied by domain of seabios.org) smtp.mailfrom=seabios-bounces@seabios.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from mail.coreboot.org (mail.coreboot.org [80.81.252.135]) by mx.zohomail.com with SMTPS id 1527748492905671.1202362857761; Wed, 30 May 2018 23:34:52 -0700 (PDT) Received: from [127.0.0.1] (helo=ra.coreboot.org) by mail.coreboot.org with esmtp (Exim 4.86_2) (envelope-from ) id 1fOHDr-0001my-DT; Thu, 31 May 2018 08:38:07 +0200 Received: from mx3-rdu2.redhat.com ([66.187.233.73] helo=mx1.redhat.com) by mail.coreboot.org with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.86_2) (envelope-from ) id 1fOHDb-0001kq-S0 for seabios@seabios.org; Thu, 31 May 2018 08:38:06 +0200 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 5339D722FC for ; Thu, 31 May 2018 06:34:07 +0000 (UTC) Received: from sirius.home.kraxel.org (ovpn-117-13.ams2.redhat.com [10.36.117.13]) by smtp.corp.redhat.com (Postfix) with ESMTP id 05781210C6CE; Thu, 31 May 2018 06:34:07 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 3D4004F284; Thu, 31 May 2018 08:34:06 +0200 (CEST) From: Gerd Hoffmann To: seabios@seabios.org Date: Thu, 31 May 2018 08:33:51 +0200 Message-Id: <20180531063353.21777-5-kraxel@redhat.com> In-Reply-To: <20180531063353.21777-1-kraxel@redhat.com> References: <20180531063353.21777-1-kraxel@redhat.com> X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Thu, 31 May 2018 06:34:07 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.11.55.2]); Thu, 31 May 2018 06:34:07 +0000 (UTC) for IP:'10.11.54.4' DOMAIN:'int-mx04.intmail.prod.int.rdu2.redhat.com' HELO:'smtp.corp.redhat.com' FROM:'kraxel@redhat.com' RCPT:'' X-Spam-Score: -6.5 (------) Subject: [SeaBIOS] [PATCH 4/6] cbvga_setup_modes: use real mode number instead of 0x140 X-BeenThere: seabios@seabios.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: SeaBIOS mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Gerd Hoffmann MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Errors-To: seabios-bounces@seabios.org Sender: "SeaBIOS" X-Duff: Orig. Duff, Duff Lite, Duff Dry, Duff Dark, Raspberry Duff, Lady Duff, Red Duff, Tartar Control Duff X-ZohoMail: RSF_4 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" In case the framebuffer size matches one of the cbvga video modes just use that mode number instead of 0x140. Signed-off-by: Gerd Hoffmann --- vgasrc/cbvga.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/vgasrc/cbvga.c b/vgasrc/cbvga.c index 672daa604c..2139a00904 100644 --- a/vgasrc/cbvga.c +++ b/vgasrc/cbvga.c @@ -263,6 +263,11 @@ cbvga_setup_modes(u64 addr, u8 bpp, u32 xlines, u32 yl= ines, u32 linelength) dprintf(3, "Removing mode %x\n", GET_GLOBAL(cbmode_g->mode)); SET_VGA(cbmode_g->mode, 0xffff); } + if ((GET_GLOBAL(cbmode_g->info.height) =3D=3D ylines) + && (GET_GLOBAL(cbmode_g->info.width) =3D=3D xlines) + && (GET_GLOBAL(cbmode_g->info.depth) =3D=3D bpp)) { + SET_VGA(CBmode, GET_GLOBAL(cbmode_g->mode)); + } } } =20 --=20 2.9.3 _______________________________________________ SeaBIOS mailing list SeaBIOS@seabios.org https://mail.coreboot.org/mailman/listinfo/seabios