1
0
Fork 0
forked from len0rd/rockbox
foxbox/firmware/target
Solomon Peachy 1f43b14127 linux-fbdev: Don't overrun the framebuffer when it's larger than expected
We expect a fixed FRAMEBUFFER_SIZE that's width*height*bitdepth, and we
mmap()ed that in.  However, when doing the initial fb clear, we
were using the hardware-provided 'finfo.smem_len' which could be
larger than FRAMEBUFFER_SIZE.  This overran our mmap and triggered
a segfault.

Correct this by mmaping (and clearing) the entire smem_len.  As a safety
measure, panic if smem_len is smaller than our expected FRAMEBUFFER_SIZE

Change-Id: I3222139c7aed6e8e8ee232b1730edd5cd70065ff
2025-05-02 11:42:31 -04:00
..
arm pp5002: Fix warning in the USB detection code 2025-04-30 07:22:38 -04:00
coldfire Remove BATTERY_TYPES 2025-03-11 02:26:38 -04:00
hosted linux-fbdev: Don't overrun the framebuffer when it's larger than expected 2025-05-02 11:42:31 -04:00
mips misc: Properly annotate some intentional case fallthroughs 2025-04-22 20:54:37 -04:00