Re: [PATCH v4 5/5] drm/ofdrm: Support big-endian scanout buffers
From: "Arnd Bergmann" <arnd@arndb.de>
Date: 2022-10-12 13:13:06
Also in:
dri-devel, linuxppc-dev
From: "Arnd Bergmann" <arnd@arndb.de>
Date: 2022-10-12 13:13:06
Also in:
dri-devel, linuxppc-dev
On Wed, Oct 12, 2022, at 2:00 PM, Thomas Zimmermann wrote:
Could well be. But ofdrm intents to replace offb and this test has worked well in offb for almost 15 yrs. If there are bug reports, I'm happy to take patches, but until then I see no reason to change it.
I wouldn't change the code in offb unless a user reports a bug,
but I don't see a point in adding the same mistake to ofdrm if we
know it can't work on real hardware.
I tried to find out where this is configured in qemu, but it seems
to depend on the framebuffer backend there: most are always little-endian,
ati/bochs/vga-pci/virtio-vga are configurable from the guest through
some register setting, but vga.c picks a default from the
'TARGET_WORDS_BIGENDIAN' macro, which I think is set differently
between qemu-system-ppc64le and qemu-system-ppc64.
If you are using the framebuffer code from vga.c, I would guess that
that you can run a big-endian kernel with qemu-system-ppc64,
or a little-endian kernel with qemu-system-ppc64le and get the
correct colors, while running a little-endian kernel with
qemu-system-ppc64 and vga.c, or using a different framebuffer
emulation on a big-endian kernel would give you the wrong colors.
Which combinations did you actually test?
Arnd