Skip to content

drm: Fix rounding errors and use scaling in i915, v2.

Maarten Lankhorst dri-devel intel-gfx 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 6 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5drm/rect: Round above 1 << 16 upwards to correct scale calculation functions.drivers/gpu/drm/drm_rect.c+16 -11 reply
2/5drm/rect: Handle rounding errors in drm_rect_clip_scaled, v3.drivers/gpu/drm/drm_atomic_helper.c drivers/gpu/drm/drm_rect.c drivers/gpu/drm/i915/intel_sprite.c +1 more+35 -171 reply
3/5drm/i915: Do not adjust scale when out of bounds, v2.drivers/gpu/drm/i915/intel_sprite.c+35 -1091 reply
4/5drm/selftests: Rename the Kconfig option to CONFIG_DRM_DEBUG_SELFTESTdrivers/gpu/drm/Kconfig drivers/gpu/drm/Makefile drivers/gpu/drm/selftests/Makefile+6 -61 reply
5/5drm/selftests: Add drm helper selftestdrivers/gpu/drm/Kconfig drivers/gpu/drm/selftests/Makefile drivers/gpu/drm/selftests/drm_helper_selftests.h +1 more+258 -12 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchVille Syrjälä
1/5R-b
2/5R-b
3/5R-b
4/5R-b
5/5R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/5] [PATCH 0/5] drm: Fix rounding errors and use scaling in i915, v2.

There were some small rounding errors in when clamping with 1.0001 and 0.9999 scaling, solve these and add a testcase for drm helpers, which can be used to prevent more of these errors in the future.

The new handling in drm_rect_clip_scaled rounds scaling towards 1.0x but because the rounding error is only 1 pixel with the new math, we won't ever get in a situation where we go from 1.001 to .999

Maarten Lankhorst (5):
drm/rect: Round above 1 << 16 upwards to correct scale calculation
functions.
drm/rect: Handle rounding errors in drm_rect_clip_scaled, v3. drm/i915: Do not adjust scale when out of bounds, v2. drm/selftests: Rename the Kconfig option to CONFIG_DRM_DEBUG_SELFTEST drm/selftests: Add drm helper selftest

 drivers/gpu/drm/Kconfig                       |   9 +-
 drivers/gpu/drm/Makefile                      |   2 +-
 drivers/gpu/drm/drm_atomic_helper.c           |   2 +-
 drivers/gpu/drm/drm_rect.c                    |  62 ++++-
 drivers/gpu/drm/i915/intel_sprite.c           | 144 +++-------
 drivers/gpu/drm/selftests/Makefile            |   2 +-
 .../gpu/drm/selftests/drm_helper_selftests.h  |   9 +
 drivers/gpu/drm/selftests/test-drm-helper.c   | 247 ++++++++++++++++++
 include/drm/drm_rect.h                        |   3 +-
 9 files changed, 348 insertions(+), 132 deletions(-)
 create mode 100644 drivers/gpu/drm/selftests/drm_helper_selftests.h
 create mode 100644 drivers/gpu/drm/selftests/test-drm-helper.c
Signature · 6 lines
2.17.0

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel