modesetting: Fix dirty updates for sw rotation

Graphics / X.Org / X.Org Server - Patrik Jakobsson [] - 15 September 2021 20:31 UTC

Rotation is broken for all drm drivers not providing hardware rotation support. Drivers that give direct access to vram and not needing dirty updates still work but only by accident. The problem is caused by modesetting not sending the correct fb_id to drmModeDirtyFB() and passing the damage rects in the rotated state and not as the crtc expects them. This patch takes care of both problems.

db9e9d45e modesetting: Fix dirty updates for sw rotation
hw/xfree86/drivers/modesetting/driver.c | 81 ++++++++++++++++++------
hw/xfree86/drivers/modesetting/drmmode_display.c | 2 +-
hw/xfree86/drivers/modesetting/drmmode_display.h | 2 +
3 files changed, 63 insertions(+), 22 deletions(-)


  • Share