public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
* [igt-dev] [PATCH i-g-t 1/5] lib/igt_fb: Fix the cairo shadow buffer stride
@ 2019-04-18 19:40 Ville Syrjala
  2019-04-18 19:40 ` [igt-dev] [PATCH i-g-t 2/5] lib/igt_fb: Fix 32bit integer overflow in the shadow buffer size calculation Ville Syrjala
                   ` (8 more replies)
  0 siblings, 9 replies; 16+ messages in thread
From: Ville Syrjala @ 2019-04-18 19:40 UTC (permalink / raw)
  To: igt-dev

From: Ville Syrjälä <ville.syrjala@linux.intel.com>

We're currently overallocating the shadow buffer stride by a
factor of 8. This didn't go down so well when I tried to use
a 16kx16k float framebuffer.

Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Fixes: b0033d9310c1 ("lib/color_encoding: Prepare support for HDR modes, v2.")
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
---
 lib/igt_fb.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index b4d354825b10..f36096804fdd 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -1911,7 +1911,7 @@ static void *igt_fb_create_cairo_shadow_buffer(int fd,
 		drm_format, LOCAL_DRM_FORMAT_MOD_NONE,
 		IGT_COLOR_YCBCR_BT709, IGT_COLOR_YCBCR_LIMITED_RANGE);
 
-	shadow->strides[0] = ALIGN(width * shadow->plane_bpp[0], 16);
+	shadow->strides[0] = ALIGN(width * (shadow->plane_bpp[0] / 8), 16);
 	shadow->size = ALIGN(shadow->strides[0] * height,
 			     sysconf(_SC_PAGESIZE));
 	ptr = mmap(NULL, shadow->size, PROT_READ | PROT_WRITE,
-- 
2.21.0

_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

^ permalink raw reply related	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2019-04-29 10:24 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-18 19:40 [igt-dev] [PATCH i-g-t 1/5] lib/igt_fb: Fix the cairo shadow buffer stride Ville Syrjala
2019-04-18 19:40 ` [igt-dev] [PATCH i-g-t 2/5] lib/igt_fb: Fix 32bit integer overflow in the shadow buffer size calculation Ville Syrjala
2019-04-26 19:14   ` Chris Wilson
2019-04-18 19:40 ` [igt-dev] [PATCH i-g-t 3/5] lib/rendercopy: Add fp16 support for gen4+ Ville Syrjala
2019-04-26 19:16   ` Chris Wilson
2019-04-18 19:40 ` [igt-dev] [PATCH i-g-t 4/5] lib/rendercopy: Configure MOCS more consistently Ville Syrjala
2019-04-26 19:18   ` Chris Wilson
2019-04-26 19:27     ` Ville Syrjälä
2019-04-18 19:40 ` [igt-dev] [PATCH i-g-t 5/5] tests/kms_big_fb: Make sure huge fbs work correctly Ville Syrjala
2019-04-26 16:50   ` [igt-dev] [PATCH i-g-t v2 " Ville Syrjala
2019-04-18 20:34 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/5] lib/igt_fb: Fix the cairo shadow buffer stride Patchwork
2019-04-18 22:46 ` [igt-dev] ✗ Fi.CI.IGT: failure " Patchwork
2019-04-26 17:59 ` [igt-dev] ✓ Fi.CI.BAT: success for series starting with [i-g-t,1/5] lib/igt_fb: Fix the cairo shadow buffer stride (rev2) Patchwork
2019-04-26 19:14 ` [igt-dev] [PATCH i-g-t 1/5] lib/igt_fb: Fix the cairo shadow buffer stride Chris Wilson
2019-04-26 23:41 ` [igt-dev] ✗ Fi.CI.IGT: failure for series starting with [i-g-t,1/5] lib/igt_fb: Fix the cairo shadow buffer stride (rev2) Patchwork
2019-04-29 10:24   ` Ville Syrjälä

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox