@samitouri / QOSamiQemu / commits / 3445dd26ec

hw/m68k/q800: Use MacFbMode fields in q800_machine_init()

Once the Mac Frame Buffer device is realized on the NuBus, its MacFbMode might be different of the global graphic_depth and graphic_width globals. Prefer the device MacFbMode fields to initialize the BootInfo structure. Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org> Reviewed-by: Pierrick Bouvier <pierrick.bouvier@linaro.org> Reviewed-by: Mark Cave-Ayland <mark.cave-ayland@ilande.co.uk> Message-Id: <20260216213121.47122-4-philmd@linaro.org>

Philippe Mathieu-Daudé committed Feb 11, 2026 at 14:45 UTC 3445dd26ecbd7a731f73e586dae3410a24b576d1
1 file changed +2 -2
hw/m68k/q800.c
+2 -2
@@ -605,9 +605,9 @@ static void q800_machine_init(MachineState *machine)
605 BOOTINFO2(param_ptr, BI_MEMCHUNK, 0, ram_size);
606 BOOTINFO1(param_ptr, BI_MAC_VADDR,
607 VIDEO_BASE + macfb_mode->offset);
608 - BOOTINFO1(param_ptr, BI_MAC_VDEPTH, graphic_depth);
608 + BOOTINFO1(param_ptr, BI_MAC_VDEPTH, macfb_mode->depth);
609 BOOTINFO1(param_ptr, BI_MAC_VDIM,
610 - (graphic_height << 16) | graphic_width);
610 + (graphic_height << 16) | macfb_mode->width);
611 BOOTINFO1(param_ptr, BI_MAC_VROW, macfb_mode->stride);
612 BOOTINFO1(param_ptr, BI_MAC_SCCBASE, SCC_BASE);
613