Implement support for framebuffers that don't start on a page boundary.
authorkettenis <kettenis@openbsd.org>
Fri, 15 Jul 2022 17:57:25 +0000 (17:57 +0000)
committerkettenis <kettenis@openbsd.org>
Fri, 15 Jul 2022 17:57:25 +0000 (17:57 +0000)
commit63294167c4eaf171adac4fb2d8cc6d072a13af61
tree33a31d60bedfb129ab9544077bbfd74789aa7c5f
parent91fc4dda8d0d7cb149281baec1900502eccf803b
Implement support for framebuffers that don't start on a page boundary.
This happens on the new 14" and 16" Macbook Pro where we deliberately use
a framebuffer that skips the first few lines to avoid "the notch".
The offset of the first pixel is added to struct wsdisplay_fbinfo.  The
stride is added as well, mirroring the value returned by the
WSDISPLAYIO_LINEBYTES ioctl, such that we can retire that one in the
future.  A compat ioctl is implemented to help the transition.  The compat
code will be removed after OpenBSD 7.3 has been released.

ok miod@
39 files changed:
sys/arch/amd64/amd64/efifb.c
sys/arch/armv7/omap/amdisplay.c
sys/arch/armv7/omap/omdisplay.c
sys/arch/loongson/dev/radeonfb.c
sys/arch/loongson/dev/sisfb.c
sys/arch/loongson/dev/smfb.c
sys/arch/luna88k/dev/lunafb.c
sys/arch/macppc/pci/vgafb.c
sys/arch/powerpc64/dev/astfb.c
sys/arch/sparc64/dev/creator.c
sys/arch/sparc64/dev/gfb.c
sys/arch/sparc64/dev/gfxp.c
sys/arch/sparc64/dev/ifb.c
sys/arch/sparc64/dev/machfb.c
sys/arch/sparc64/dev/radeonfb.c
sys/arch/sparc64/dev/raptor.c
sys/arch/sparc64/dev/vgafb.c
sys/dev/fdt/rkdrm.c
sys/dev/fdt/simplefb.c
sys/dev/fdt/ssdfb.c
sys/dev/ic/sti.c
sys/dev/pci/drm/amd/amdgpu/amdgpu_kms.c
sys/dev/pci/drm/i915/i915_drv.c
sys/dev/pci/drm/radeon/radeon_kms.c
sys/dev/pci/tga.c
sys/dev/pcmcia/cfxga.c
sys/dev/sbus/agten.c
sys/dev/sbus/bwtwo.c
sys/dev/sbus/cgsix.c
sys/dev/sbus/cgthree.c
sys/dev/sbus/cgtwelve.c
sys/dev/sbus/mgx.c
sys/dev/sbus/rfx.c
sys/dev/sbus/tvtwo.c
sys/dev/sbus/vigra.c
sys/dev/sbus/zx.c
sys/dev/usb/udl.c
sys/dev/wscons/wsconsio.h
sys/dev/wscons/wsdisplay.c