qemu-arm
[Top][All Lists]
Advanced

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

Re: [PATCH v2] hw/display/bcm2835_fb: Fix framebuffer allocation address


From: Peter Maydell
Subject: Re: [PATCH v2] hw/display/bcm2835_fb: Fix framebuffer allocation address
Date: Tue, 26 Jul 2022 15:04:54 +0100

On Mon, 25 Jul 2022 at 16:06, Alan Jian <alanjian85@gmail.com> wrote:
>
> This patch fixes the dedicated framebuffer mailbox interface(marked as
> deprecated in official docs, but can still be fixed for emulation purposes)
> by removing unneeded offset to make it works like buffer allocate tag in
> bcm2835_property interface[1], some baremetal applications like the
> Screen01/Screen02 examples from Baking Pi tutorial[2] didn't work
> before this patch.
>
> [1] https://github.com/qemu/qemu/blob/master/hw/misc/bcm2835_property.c#L158
> [2] https://www.cl.cam.ac.uk/projects/raspberrypi/tutorials/os/screen01.html

Thanks. If examples which work on real hardware don't work on QEMU
then we presumably have a bug, and the documentation of this fb mbox
https://github.com/raspberrypi/firmware/wiki/Mailbox-framebuffer-interface
doesn't say anything about using the top bits of the config-struct
address for anything, so the current code definitely looks wrong.

This was the only place where we ever changed the config
struct's .base field to something other than s->vcram_base + BCM2835_FB_OFFSET.
If the .base field is now effectively constant then it's pointless
and we can clean things up a bit by getting rid of it. I'll send a
followup patch at some point.

Applied to target-arm.next, thanks. (I tweaked the commit message
slightly.)

-- PMM



reply via email to

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