It is useless to adjust the file of screen

Maybe the comment was not very clear: wether this works or not depends on if the code can find and patch the video mode tables in the bios. I got the information on table formats from Clover, a bootloader from the hackintosh community, which had implemented a similar thing. But I found that on my hardware it wouldn’t work at all, because the table format is different, or maybe there are more places to patch.

On hardware where it works, there should be no problem. So we can enable it by default there, and keep it disabled for other devices, until someone decides to figure out how the bios stores videomodes and what needs to be patched.

1 Like

my other pc with 7 inch screen.
when i run with vga mode, and get the right display, then i reboot to gpu mode .

it will auto be a strange display.

and the vesa file will be auto rewrite,

here is my information.

~> screenfetch
:dc’ user@shredder
‘l:;’,'ck. .;dc:. OS: Haiku hrev57937+121
co …k. .;; ‘:o. Kernel: x86_64 Haiku 1
co …k. ol .0. Uptime:
co …k. oc …0. Packages: 627
co …k. oc …0. Shell: bash 5.2.32
.Ol,. co …’'Oc;kkodxOdddOoc,. Resolution: 1280x1024
‘;lxxlxOdxkxk0kdooolldlccc:clxd; Disk: writable / is ()
…oOolllllccccccc:::::od; CPU: Intel Core i7-5500U @ 2.40GHz
cx:ooc:::::::;cooolcX. GPU: HD Graphics 5500
cd.’‘cloxdoollc’ …0. RAM: 697MiB / 8016MiB
cd…k;.xl… .0.
.::c;…cx;.xo… .0.
‘::c’…do… .K,
cd,…:O,…
‘:clod:’…
.
~> screeninfo
Screen 0: attached
version: 1
name: Intel Atom
chipset: Broadwell GT2 ULT
serial: None
bitmap overlay colorspaces supported:
~> listdev

device Bridge (Host bridge) [6|0|0]
vendor 8086: Intel Corporation
device 1604: Broadwell-U Host Bridge -OPI

device Display controller (VGA compatible controller, VGA controller) [3|0|0]
vendor 8086: Intel Corporation
device 1616: HD Graphics 5500

device Multimedia controller (Audio device) [4|3|0]
vendor 8086: Intel Corporation
device 160c: Broadwell-U Audio Controller

device Serial bus controller (USB controller, XHCI) [c|3|30]
vendor 8086: Intel Corporation
device 9cb1: Wildcat Point-LP USB xHCI Controller

device Hub (Unused, Full speed (or root) hub) [9|0|0]
vendor 0000: Unknown
device 0000: Unknown

  device Hub (Unused, Full speed (or root) hub) [9|0|0]
    vendor 1a40: Terminus Technology Inc.
    device 0101: Hub

     device Wireless (Radio Frequency, Bluetooth) [e0|1|1]
       vendor 0cf3: Qualcomm Atheros Communications
       device 3004: AR3012 Bluetooth 4.0

  device Human Interface Device (Boot Interface Subclass, Mouse) [3|1|2]
    vendor 040a: Kodak Co.
    device 2814: Unknown

  device Mass Storage (SCSI, Bulk-Only) [8|6|50]
    vendor 0951: Kingston Technology
    device 1643: DataTraveler G3

  device Human Interface Device (Boot Interface Subclass, Mouse) [3|1|2]
    vendor 0101: Unknown
    device 0007: Unknown

device Communication controller [7|80|0]
vendor 8086: Intel Corporation
device 9cba: Wildcat Point-LP MEI Controller #1

device Multimedia controller (Audio device) [4|3|0]
vendor 8086: Intel Corporation
device 9ca0: Wildcat Point-LP High Definition Audio Controller

device Bridge (PCI bridge, Normal decode) [6|4|0]
vendor 8086: Intel Corporation
device 9c90: Wildcat Point-LP PCI Express Root Port #1

device Bridge (PCI bridge, Normal decode) [6|4|0]
vendor 8086: Intel Corporation
device 9c94: Wildcat Point-LP PCI Express Root Port #3

device Network controller (Ethernet controller) [2|0|0]
vendor 10ec: Realtek Semiconductor Co., Ltd.
device 8168: RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller

device Bridge (PCI bridge, Normal decode) [6|4|0]
vendor 8086: Intel Corporation
device 9c96: Wildcat Point-LP PCI Express Root Port #4

device Network controller [2|80|0]
vendor 168c: Qualcomm Atheros
device 0034: AR9462 Wireless Network Adapter

device Bridge (PCI bridge, Normal decode) [6|4|0]
vendor 8086: Intel Corporation
device 9c98: Wildcat Point-LP PCI Express Root Port #5

device Network controller (Ethernet controller) [2|0|0]
vendor 10ec: Realtek Semiconductor Co., Ltd.
device 8168: RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet Controller

device Serial bus controller (USB controller, EHCI) [c|3|20]
vendor 8086: Intel Corporation
device 9ca6: Wildcat Point-LP USB EHCI Controller

device Hub (Unused, Full speed (or root) hub) [9|0|0]
vendor 0000: Unknown
device 0000: Unknown

  device Hub (Unused, Full speed (or root) hub) [9|0|0]
    vendor 8087: Intel Corp.
    device 8001: Integrated Hub

device Bridge (ISA bridge) [6|1|0]
vendor 8086: Intel Corporation
device 9cc3: Wildcat Point-LP LPC Controller

device Mass storage controller (SATA controller, AHCI 1.0) [1|6|1]
vendor 8086: Intel Corporation
device 9c83: Wildcat Point-LP SATA Controller [AHCI Mode]

device Serial bus controller (SMBus) [c|5|0]
vendor 8086: Intel Corporation
device 9ca2: Wildcat Point-LP SMBus Controller
~> cat ./config/settings/kernel/drivers/vesa
mode 1280 1024 32
~>

guys, it be ok.

bios + hdmi + gpu + 7 inch monitor

it will auto be 1024X600 .

only need these information in the vesa file.

haiku don’t like weird monitor. hahahahahaha
(it still get the wrong information of the 7 inch monitor.)

the 21.5 inch monitor also be ok. (1920X1080)

i think you should take it as default.
and, please don’t let haiku to rewrite it.(many people have lots of monitors. they will switch frequently。

both of them are ok.

haiku can auto get the right display.

i guess most of monitor are between 7 inch and 21.5 inch.

# /boot/home/config/settings/kernel/drivers/vesa
bios_patching true
mode 800 600 32

1 Like

AFAIK, the vesa config file is only used with the VESA/framebuffer driver.

In your latest screenshot, the Screen preferences show “Intel Atom (Broadwell GT2 ULT)”, so it is running a specific driver for your graphics chip and it doesn’t matter what the vesa file says (for the desktop; it’s still used while booting).

In the first one you see it says “VESA driver (Generic VESA)”. That one does use the settings in the vesa config file.

BIOS patching is also independent of the monitor. What does depend on the monitor is the list of video modes, which I think is the set that both the monitor and the graphics driver report as supported. Different monitors may report different modes, of course. Likewise, the VESA driver may report a very small set of standard modes, but when patching works, it accepts any.

Now, given that BIOS patching is a very unused feature, there are of course things to improve. In my test, patching works but I don’t boot to my preferred mode. And then setting the mode in Screen preferences overwrites the config file, removing the bios_patching line.

1 Like

If this is also going to be enabled in safe mode, here’s my laptop’s, already supported by intel_extreme:

device Display controller (VGA compatible controller, VGA controller) [3|0|0]
  vendor 8086: Intel Corporation
  device 0046: Core Processor Integrated Graphics Controller

It’s possible in a uefi machine booting in legacy mode to use correctly vesa driver if the native driver has problems loaded.

I thought if you boot with UEFI mode, you will get Framebuffer instead of VESA!
How to boot with UEFI and get VESA mode?
If the native driver is not available in HAIKU, you will get Framebuffer or VESA mode…
so what?

Simply

Press the key for the boot menu of the uefi and if you have CSM enabled you can select to boot the hard drive in legacy mode. Which triggers the vesa driver.

You can’t get vesa when booting with uefi, vesa is tied to using a bios.

Sure, you can always use bios/lgacy booting on most current uefi machines. I guess this option will be going away in the next few years.

1 Like

There are a lot of devices already that don’t support CSM/Legacy mode.
I own a few and some aren’t that new even.
I prefer using BIOS booting where it still works due to it’s simplicity and that it just works,but you can’t take it for granted anymore.

1 Like

Watch any youtube video or forum thread about “Haiku doesn’t boot” and find out that most people fail to partition their disk with the correct layout, or don’t have a master boot record compatible with Haiku, or didn’t set a partition as active.

Remeber that to support VESA, we have to emulate an x86 CPU inside app_server to run the VESA BIOS while the OS has put the CPU in protected mode or even in 64 bit mode. And we are also working on live patching that BIOS to inject extra video modes in it.

BIOS isn’t simple. It’s a very old and quirky thing with arbitrary limitations. It is just slightly better integrated in Haiku than EFI is, and more well-known by people who have used computers in the 90s. But that does not equal simplicity.

2 Likes

it seems that haiku need a auto script with UEFI mode。

2 Likes

On an Atom N2600 based netbook:

device Display controller (VGA compatible controller, VGA controller) [3|0|0]
  vendor 8086: Intel Corporation
  device 0be1: Atom Processor D2xxx/N2xxx Integrated Graphics Controller

bios_patching true works. Available resolution go from 6 to 17 after patching (albeit not all of them work OK, and some like 1920x1080 force you to power off, as the screen becomes garbled and doesn’t recovers with the "“do you wish to keep these settings”).

Sorry for the delay, november has been busy (worse than usual).

Anyway, here is a patch to enaple bios patching by default on that device, still allowing the vesa settings file to force it on or off: https://review.haiku-os.org/c/haiku/+/8633

4 Likes