qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH-for-9.2? v2 1/2] hw/display/vga: Do not reset 'big_endian_fb'


From: BALATON Zoltan
Subject: Re: [PATCH-for-9.2? v2 1/2] hw/display/vga: Do not reset 'big_endian_fb' in vga_common_reset()
Date: Tue, 3 Dec 2024 13:21:36 +0100 (CET)

On Tue, 3 Dec 2024, Gerd Hoffmann wrote:
 Hi,

For bochs and ati, there's a register to configure it as well, so there
*may* be an expectation that it gets reset there, I'm less certain.

The default is there for backward compatibility reasons and it should
default to machine byte order so you get something working even in case
the guest does not explicitly set the byte order via register.  Which
should be increasingly rare these days, the register was added in
(checking git log) 2014: commit b5682aa4ca79 ("vga-pci: add qext region
to mmio")

The only case I'm aware of where the byte order is actually switched is
booting a ppc64le guest in a pseries machine, where the opal firmware
runs in bigendian mode and the linux kernel runs in little endian mode.

So here the changed reset behavior could actually make a difference, but
you will only notice if the opal firmware does *not* set the byte order
register.

I'm not sure about ati-vga but I set the vga.big_endian_fb on mode switch if the guest uses big endian mode. I've added this for MacOS 9 I think which does use that. I've also put some notes on what I've found different drivers use in commit 8bb9a2b26d83a. AFAIK the ati chip starts as little endian so maybe reseting it in ati_vga_reset() if vga_common_reset() does not do that any more may be needed but I can't tell for sure that's why I did not comment on this patch so far.

Regards,
BALATON Zoltan



reply via email to

[Prev in Thread] Current Thread [Next in Thread]