NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: install/59485: sysinst unusable on smaller framebuffer resolutions
The following reply was made to PR install/59485; it has been noted by GNATS.
From: mlelstv%serpens.de@localhost (Michael van Elst)
To: gnats-bugs%netbsd.org@localhost
Cc:
Subject: Re: install/59485: sysinst unusable on smaller framebuffer resolutions
Date: Wed, 25 Jun 2025 05:19:05 -0000 (UTC)
uwe%stderr.spb.ru@localhost writes:
>>How-To-Repeat:
>Try to use sysinst on a lower resolution monitor.
>>Fix:
>May be hi-res workaround in the driver should not be applied if the
>resulting terminal will be less than 80 columns?
Maybe this:
Index: sys/dev/wsfb/genfb.c
===================================================================
RCS file: /cvsroot/src/sys/dev/wsfb/genfb.c,v
retrieving revision 1.92
diff -p -u -r1.92 genfb.c
--- sys/dev/wsfb/genfb.c 29 Apr 2025 12:20:36 -0000 1.92
+++ sys/dev/wsfb/genfb.c 25 Jun 2025 05:15:49 -0000
@@ -781,12 +781,14 @@ static int
genfb_calc_cols(struct genfb_softc *sc, struct rasops_info *ri)
{
const int hsize = genfb_calc_hsize(sc);
+ const int cols = hsize ? hsize / GENFB_CHAR_WIDTH_MM : RASOPS_DEFAULT_WIDTH;
- if (hsize != 0) {
+ if (hsize != 0 &&
+ cols > 2 * RASOPS_DEFAULT_WIDTH) {
ri->ri_flg |= RI_PREFER_WIDEFONT;
}
- return MAX(RASOPS_DEFAULT_WIDTH, hsize / GENFB_CHAR_WIDTH_MM);
+ return MIN(cols, hsize / GENFB_CHAR_WIDTH_MM);
}
static int
Home |
Main Index |
Thread Index |
Old Index