All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller
@ 2016-01-26 13:28 Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 2/6] kms_frontbuffer_tracking: use igt_drm_format_to_bpp() Paulo Zanoni
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:28 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

The big motivation behind this patch is that the current power-of-two
granularity from igt_fb is way too big. There was more than one
occasion where I had to work around this problem on
kms_frontbuffer_tracking, and during my last workaround I was
requested to just make igt_fb use more minimal buffers.

I also need to export the size computation function so I won't need to
reimplement it inside kms_frontbuffer_tracking.

v2:
 - Fix the Yf sizes (Ville).
 - Don't change the non-tiled Gen 2/3 behavior.

Requested-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 lib/igt_fb.c | 111 ++++++++++++++++++++++++++++++++++++++++++++++++++---------
 lib/igt_fb.h |   2 ++
 2 files changed, 96 insertions(+), 17 deletions(-)

diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index c985824..2f8968d 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -32,6 +32,7 @@
 #include "drmtest.h"
 #include "igt_fb.h"
 #include "ioctl_wrappers.h"
+#include "intel_chipset.h"
 
 /**
  * SECTION:igt_fb
@@ -72,26 +73,88 @@ static struct format_desc_struct {
 #define for_each_format(f)	\
 	for (f = format_desc; f - format_desc < ARRAY_SIZE(format_desc); f++)
 
+static void igt_get_fb_tile_size(int fd, uint64_t tiling, int fb_bpp,
+				 unsigned *width_ret, unsigned *height_ret)
+{
+	uint32_t devid = intel_get_drm_devid(fd);
 
-/* helpers to create nice-looking framebuffers */
-static int create_bo_for_fb(int fd, int width, int height, int bpp,
-			    uint64_t tiling, unsigned bo_size,
-			    unsigned bo_stride, uint32_t *gem_handle_ret,
-			    unsigned *size_ret, unsigned *stride_ret)
+	switch (tiling) {
+	case LOCAL_DRM_FORMAT_MOD_NONE:
+		*width_ret = 64;
+		*height_ret = 1;
+		break;
+	case LOCAL_I915_FORMAT_MOD_X_TILED:
+		if (intel_gen(devid) == 2) {
+			*width_ret = 128;
+			*height_ret = 16;
+		} else {
+			*width_ret = 512;
+			*height_ret = 8;
+		}
+		break;
+	case LOCAL_I915_FORMAT_MOD_Y_TILED:
+		if (IS_915(devid))
+			*width_ret = 512;
+		else
+			*width_ret = 128;
+		*height_ret = 32;
+		break;
+	case LOCAL_I915_FORMAT_MOD_Yf_TILED:
+		switch (fb_bpp) {
+		case 8:
+			*width_ret = 64;
+			*height_ret = 64;
+			break;
+		case 16:
+		case 32:
+			*width_ret = 128;
+			*height_ret = 32;
+			break;
+		case 64:
+		case 128:
+			*width_ret = 256;
+			*height_ret = 16;
+			break;
+		default:
+			igt_assert(false);
+		}
+		break;
+	default:
+		igt_assert(false);
+	}
+}
+
+/**
+ * igt_calc_fb_size:
+ * @fd: the DRM file descriptor
+ * @width: width of the framebuffer in pixels
+ * @height: height of the framebuffer in pixels
+ * @bpp: bytes per pixel of the framebuffer
+ * @tiling: tiling layout of the framebuffer (as framebuffer modifier)
+ * @size_ret: returned size for the framebuffer
+ * @stride_ret: returned stride for the framebuffer
+ *
+ * This function returns valid stride and size values for a framebuffer with the
+ * specified parameters.
+ */
+void igt_calc_fb_size(int fd, int width, int height, int bpp, uint64_t tiling,
+		      unsigned *size_ret, unsigned *stride_ret)
 {
-	uint32_t gem_handle;
-	int size, ret = 0;
-	unsigned stride;
+	unsigned int tile_width, tile_height, stride, size;
+	int byte_width = width * (bpp / 8);
+
+	igt_get_fb_tile_size(fd, tiling, bpp, &tile_width, &tile_height);
 
-	if (tiling != LOCAL_DRM_FORMAT_MOD_NONE) {
+	if (intel_gen(intel_get_drm_devid(fd)) <= 3 &&
+	    tiling != LOCAL_DRM_FORMAT_MOD_NONE) {
 		int v;
 
-		/* Round the tiling up to the next power-of-two and the
-		 * region up to the next pot fence size so that this works
-		 * on all generations.
+		/* Round the tiling up to the next power-of-two and the region
+		 * up to the next pot fence size so that this works on all
+		 * generations.
 		 *
-		 * This can still fail if the framebuffer is too large to
-		 * be tiled. But then that failure is expected.
+		 * This can still fail if the framebuffer is too large to be
+		 * tiled. But then that failure is expected.
 		 */
 
 		v = width * bpp / 8;
@@ -102,11 +165,25 @@ static int create_bo_for_fb(int fd, int width, int height, int bpp,
 		for (size = 1024*1024; size < v; size *= 2)
 			;
 	} else {
-		/* Scan-out has a 64 byte alignment restriction */
-		stride = ALIGN(width * (bpp / 8), 64);
-		size = stride * height;
+		stride = ALIGN(byte_width, tile_width);
+		size = stride * ALIGN(height, tile_height);
 	}
 
+	*stride_ret = stride;
+	*size_ret = size;
+}
+
+/* helpers to create nice-looking framebuffers */
+static int create_bo_for_fb(int fd, int width, int height, int bpp,
+			    uint64_t tiling, unsigned bo_size,
+			    unsigned bo_stride, uint32_t *gem_handle_ret,
+			    unsigned *size_ret, unsigned *stride_ret)
+{
+	uint32_t gem_handle;
+	int ret = 0;
+	unsigned size, stride;
+
+	igt_calc_fb_size(fd, width, height, bpp, tiling, &size, &stride);
 	if (bo_size == 0)
 		bo_size = size;
 	if (bo_stride == 0)
diff --git a/lib/igt_fb.h b/lib/igt_fb.h
index 5cc8644..064027c 100644
--- a/lib/igt_fb.h
+++ b/lib/igt_fb.h
@@ -69,6 +69,8 @@ enum igt_text_align {
 	align_hcenter	= 0x08,
 };
 
+void igt_calc_fb_size(int fd, int width, int height, int bpp, uint64_t tiling,
+		      unsigned *size_ret, unsigned *stride_ret);
 unsigned int
 igt_create_fb_with_bo_size(int fd, int width, int height,
 			   uint32_t format, uint64_t tiling,
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH igt 2/6] kms_frontbuffer_tracking: use igt_drm_format_to_bpp()
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
@ 2016-01-26 13:29 ` Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 3/6] kms_frontbuffer_tracking: standardize the used FB sizes Paulo Zanoni
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

The only format from fb_get_bpp() not supported by
igt_drm_format_to_bpp() is ARGB2101010, but we don't really use it in
kms_frontbuffer_tracking, so we can do the switch.

Adding ARGB2101010 to igt_fb won't be that simple since there's no
equivalent Cairo format, and igt_fb users assume that all formats
known by igt_fb have equivalent Cairo formats.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 tests/kms_frontbuffer_tracking.c | 17 +----------------
 1 file changed, 1 insertion(+), 16 deletions(-)

diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c
index e7acc7c..c819019 100644
--- a/tests/kms_frontbuffer_tracking.c
+++ b/tests/kms_frontbuffer_tracking.c
@@ -1102,21 +1102,6 @@ static void *busy_thread_func(void *data)
 	pthread_exit(0);
 }
 
-static int fb_get_bpp(struct igt_fb *fb)
-{
-	switch (fb->drm_format) {
-	case DRM_FORMAT_RGB565:
-		return 16;
-	case DRM_FORMAT_XRGB8888:
-	case DRM_FORMAT_ARGB8888:
-	case DRM_FORMAT_ARGB2101010:
-	case DRM_FORMAT_XRGB2101010:
-		return 32;
-	default:
-		igt_assert(false);
-	}
-}
-
 static void start_busy_thread(struct igt_fb *fb)
 {
 	int rc;
@@ -1129,7 +1114,7 @@ static void start_busy_thread(struct igt_fb *fb)
 	busy_thread.width = fb->width;
 	busy_thread.height = fb->height;
 	busy_thread.color = pick_color(fb, COLOR_PRIM_BG);
-	busy_thread.bpp = fb_get_bpp(fb);
+	busy_thread.bpp = igt_drm_format_to_bpp(fb->drm_format);
 
 	rc = pthread_create(&busy_thread.thread, NULL, busy_thread_func, NULL);
 	igt_assert_eq(rc, 0);
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH igt 3/6] kms_frontbuffer_tracking: standardize the used FB sizes
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 2/6] kms_frontbuffer_tracking: use igt_drm_format_to_bpp() Paulo Zanoni
@ 2016-01-26 13:29 ` Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 4/6] lib/igt_draw: use igt_drm_format_to_bpp() Paulo Zanoni
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

We want to make sure that both tiled and untiled buffers have the same
size for the same width/height/format. This will allow better control
over the failure paths exercised by our tests: when we try to flip
from tiled to untiled, we'll be sure that we won't execute the error
path that checks for buffer sizes.

v2: Use the new igt_calc_fb_size() instead of implementing our own
size calculation (Daniel).
v3: We can now use igt_drm_format_to_bpp() (Daniel).

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 tests/kms_frontbuffer_tracking.c | 19 ++++++++++++++++++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/tests/kms_frontbuffer_tracking.c b/tests/kms_frontbuffer_tracking.c
index c819019..64f880c 100644
--- a/tests/kms_frontbuffer_tracking.c
+++ b/tests/kms_frontbuffer_tracking.c
@@ -483,6 +483,9 @@ static void create_fb(enum pixel_format pformat, int width, int height,
 		      uint64_t tiling, int plane, struct igt_fb *fb)
 {
 	uint32_t format;
+	unsigned int size, stride;
+	int bpp;
+	uint64_t tiling_for_size;
 
 	switch (pformat) {
 	case FORMAT_RGB888:
@@ -512,7 +515,21 @@ static void create_fb(enum pixel_format pformat, int width, int height,
 		igt_assert(false);
 	}
 
-	igt_create_fb(drm.fd, width, height, format, tiling, fb);
+	/* We want all frontbuffers with the same width/height/format to have
+	 * the same size regardless of tiling since we want to properly exercise
+	 * the Kernel's specific tiling-checking code paths without accidentally
+	 * hitting size-checking ones first. */
+	bpp = igt_drm_format_to_bpp(format);
+	if (plane == PLANE_CUR)
+		tiling_for_size = LOCAL_DRM_FORMAT_MOD_NONE;
+	else
+		tiling_for_size = LOCAL_I915_FORMAT_MOD_X_TILED;
+
+	igt_calc_fb_size(drm.fd, width, height, bpp, tiling_for_size, &size,
+			 &stride);
+
+	igt_create_fb_with_bo_size(drm.fd, width, height, format, tiling, fb,
+				   size, stride);
 }
 
 static uint32_t pick_color(struct igt_fb *fb, enum color ecolor)
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH igt 4/6] lib/igt_draw: use igt_drm_format_to_bpp()
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 2/6] kms_frontbuffer_tracking: use igt_drm_format_to_bpp() Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 3/6] kms_frontbuffer_tracking: standardize the used FB sizes Paulo Zanoni
@ 2016-01-26 13:29 ` Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 5/6] lib/igt_fb: fix igt_get_all_formats documentation Paulo Zanoni
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

Don't reimplement the function.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 lib/igt_draw.c | 16 +---------------
 1 file changed, 1 insertion(+), 15 deletions(-)

diff --git a/lib/igt_draw.c b/lib/igt_draw.c
index f85e376..45fa10f 100644
--- a/lib/igt_draw.c
+++ b/lib/igt_draw.c
@@ -594,20 +594,6 @@ void igt_draw_rect(int fd, drm_intel_bufmgr *bufmgr, drm_intel_context *context,
 	}
 }
 
-static int get_format_bpp(uint32_t drm_format)
-{
-	switch (drm_format) {
-	case DRM_FORMAT_RGB565:
-		return 16;
-	case DRM_FORMAT_XRGB8888:
-	case DRM_FORMAT_ARGB8888:
-	case DRM_FORMAT_XRGB2101010:
-		return 32;
-	default:
-		igt_assert(false);
-	}
-}
-
 /**
  * igt_draw_rect_fb:
  * @fd: the DRM file descriptor
@@ -632,7 +618,7 @@ void igt_draw_rect_fb(int fd, drm_intel_bufmgr *bufmgr,
 {
 	igt_draw_rect(fd, bufmgr, context, fb->gem_handle, fb->size, fb->stride,
 		      method, rect_x, rect_y, rect_w, rect_h, color,
-		      get_format_bpp(fb->drm_format));
+		      igt_drm_format_to_bpp(fb->drm_format));
 }
 
 /**
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH igt 5/6] lib/igt_fb: fix igt_get_all_formats documentation
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
                   ` (2 preceding siblings ...)
  2016-01-26 13:29 ` [PATCH igt 4/6] lib/igt_draw: use igt_drm_format_to_bpp() Paulo Zanoni
@ 2016-01-26 13:29 ` Paulo Zanoni
  2016-01-26 13:29 ` [PATCH igt 6/6] tests/igt_fb: rename igt_get_all_formats to igt_get_all_cairo_formats Paulo Zanoni
  2016-01-26 13:40 ` [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Chris Wilson
  5 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

We give the callers a const pointer to a static variable that we reuse
between multiple calls: they're not supposed to free it, and they
don't free it today.

Fix the documentation and leave the still reachable pointer instead of
reworking the function and its callers.

Signed-off-by: Paulo Zanoni <paulo.r.zanoni@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 2f8968d..0462c35 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -1146,7 +1146,7 @@ const char *igt_format_str(uint32_t drm_format)
  * @format_count: pointer to integer to store the size of the allocated array
  *
  * This functions returns an array of all the drm fourcc codes supported by this
- * library. The caller must free the allocated array again with free().
+ * library.
  */
 void igt_get_all_formats(const uint32_t **formats, int *format_count)
 {
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH igt 6/6] tests/igt_fb: rename igt_get_all_formats to igt_get_all_cairo_formats
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
                   ` (3 preceding siblings ...)
  2016-01-26 13:29 ` [PATCH igt 5/6] lib/igt_fb: fix igt_get_all_formats documentation Paulo Zanoni
@ 2016-01-26 13:29 ` Paulo Zanoni
  2016-01-26 13:40 ` [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Chris Wilson
  5 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:29 UTC (permalink / raw)
  To: intel-gfx; +Cc: Paulo Zanoni

I recently had this discussion with Daniel where I didn't want to use
igt_drm_format_to_bpp() because it uses the format_desc array, and
igt_fb currently assumes that all the format_desc formats have a
matching valid Cairo format, so I wouldn't be able to easily add
formats such as ARGB2101010.

The function that has the assumption mentioned above is
igt_get_all_formats: its current users call igt_get_all_formats, and
then call cairo-dependent functions, such as igt_get_cairo_ctx on the
returned formats.

In order to document the current behavior and prevent any problems in
case we start adding new formats without matching Cairo versions to
format_desc, rename igt_get_all_formats to igt_get_all_cairo_formats
and make it explicitly check for CAIRO_FORMAT_INVALID.

Requested-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
---
 lib/igt_fb.c       | 22 ++++++++++++++--------
 lib/igt_fb.h       |  2 +-
 tests/kms_atomic.c |  2 +-
 tests/kms_render.c |  2 +-
 4 files changed, 17 insertions(+), 11 deletions(-)

diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index 0462c35..5f23136 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -1141,28 +1141,34 @@ const char *igt_format_str(uint32_t drm_format)
 }
 
 /**
- * igt_get_all_formats:
+ * igt_get_all_cairo_formats:
  * @formats: pointer to pointer to store the allocated formats array
  * @format_count: pointer to integer to store the size of the allocated array
  *
- * This functions returns an array of all the drm fourcc codes supported by this
- * library.
+ * This functions returns an array of all the drm fourcc codes supported by
+ * cairo and this library.
  */
-void igt_get_all_formats(const uint32_t **formats, int *format_count)
+void igt_get_all_cairo_formats(const uint32_t **formats, int *format_count)
 {
 	static uint32_t *drm_formats;
+	static int n_formats;
 
 	if (!drm_formats) {
 		struct format_desc_struct *f;
 		uint32_t *format;
 
-		drm_formats = calloc(ARRAY_SIZE(format_desc),
-				     sizeof(*drm_formats));
+		n_formats = 0;
+		for_each_format(f)
+			if (f->cairo_id != CAIRO_FORMAT_INVALID)
+				n_formats++;
+
+		drm_formats = calloc(n_formats, sizeof(*drm_formats));
 		format = &drm_formats[0];
 		for_each_format(f)
-			*format++ = f->drm_id;
+			if (f->cairo_id != CAIRO_FORMAT_INVALID)
+				*format++ = f->drm_id;
 	}
 
 	*formats = drm_formats;
-	*format_count = ARRAY_SIZE(format_desc);
+	*format_count = n_formats;
 }
diff --git a/lib/igt_fb.h b/lib/igt_fb.h
index 064027c..4e6a769 100644
--- a/lib/igt_fb.h
+++ b/lib/igt_fb.h
@@ -117,7 +117,7 @@ int igt_cairo_printf_line(cairo_t *cr, enum igt_text_align align,
 uint32_t igt_bpp_depth_to_drm_format(int bpp, int depth);
 uint32_t igt_drm_format_to_bpp(uint32_t drm_format);
 const char *igt_format_str(uint32_t drm_format);
-void igt_get_all_formats(const uint32_t **formats, int *format_count);
+void igt_get_all_cairo_formats(const uint32_t **formats, int *format_count);
 
 #endif /* __IGT_FB_H__ */
 
diff --git a/tests/kms_atomic.c b/tests/kms_atomic.c
index 501093c..c8b8b78 100644
--- a/tests/kms_atomic.c
+++ b/tests/kms_atomic.c
@@ -843,7 +843,7 @@ static uint32_t plane_get_igt_format(struct kms_atomic_plane_state *plane)
 	plane_kms = drmModeGetPlane(plane->state->desc->fd, plane->obj);
 	igt_assert(plane_kms);
 
-	igt_get_all_formats(&igt_formats, &num_igt_formats);
+	igt_get_all_cairo_formats(&igt_formats, &num_igt_formats);
 	for (i = 0; i < num_igt_formats; i++) {
 		int j;
 
diff --git a/tests/kms_render.c b/tests/kms_render.c
index 467d71f..e0a2b58 100644
--- a/tests/kms_render.c
+++ b/tests/kms_render.c
@@ -173,7 +173,7 @@ static void test_connector(const char *test_name,
 	int format_count;
 	int i;
 
-	igt_get_all_formats(&formats, &format_count);
+	igt_get_all_cairo_formats(&formats, &format_count);
 	for (i = 0; i < format_count; i++) {
 		if (intel_gen(intel_get_drm_devid(drm_fd)) < 4
 		    && formats[i] == DRM_FORMAT_XRGB2101010) {
-- 
2.7.0.rc3

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller
  2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
                   ` (4 preceding siblings ...)
  2016-01-26 13:29 ` [PATCH igt 6/6] tests/igt_fb: rename igt_get_all_formats to igt_get_all_cairo_formats Paulo Zanoni
@ 2016-01-26 13:40 ` Chris Wilson
  2016-01-26 13:48   ` Paulo Zanoni
  5 siblings, 1 reply; 8+ messages in thread
From: Chris Wilson @ 2016-01-26 13:40 UTC (permalink / raw)
  To: Paulo Zanoni; +Cc: intel-gfx

On Tue, Jan 26, 2016 at 11:28:59AM -0200, Paulo Zanoni wrote:
> The big motivation behind this patch is that the current power-of-two
> granularity from igt_fb is way too big. There was more than one
> occasion where I had to work around this problem on
> kms_frontbuffer_tracking, and during my last workaround I was
> requested to just make igt_fb use more minimal buffers.
> 
> I also need to export the size computation function so I won't need to
> reimplement it inside kms_frontbuffer_tracking.
> 
> v2:
>  - Fix the Yf sizes (Ville).
>  - Don't change the non-tiled Gen 2/3 behavior.

s/non-tiled/tiled/

You made me panic.
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller
  2016-01-26 13:40 ` [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Chris Wilson
@ 2016-01-26 13:48   ` Paulo Zanoni
  0 siblings, 0 replies; 8+ messages in thread
From: Paulo Zanoni @ 2016-01-26 13:48 UTC (permalink / raw)
  To: Chris Wilson, Paulo Zanoni, Intel Graphics Development

2016-01-26 11:40 GMT-02:00 Chris Wilson <chris@chris-wilson.co.uk>:
> On Tue, Jan 26, 2016 at 11:28:59AM -0200, Paulo Zanoni wrote:
>> The big motivation behind this patch is that the current power-of-two
>> granularity from igt_fb is way too big. There was more than one
>> occasion where I had to work around this problem on
>> kms_frontbuffer_tracking, and during my last workaround I was
>> requested to just make igt_fb use more minimal buffers.
>>
>> I also need to export the size computation function so I won't need to
>> reimplement it inside kms_frontbuffer_tracking.
>>
>> v2:
>>  - Fix the Yf sizes (Ville).
>>  - Don't change the non-tiled Gen 2/3 behavior.
>
> s/non-tiled/tiled/

We're now not-changing both.

v1 was wrongly changing gen 2/3 non-tiled behavior by treating it as tiled.
v2 fixed that, so now we're not changing both tiled and non-tiled behavior

>
> You made me panic.

I can see the confusion. I'll change the wording before pushing.


> -Chris
>
> --
> Chris Wilson, Intel Open Source Technology Centre
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx



-- 
Paulo Zanoni
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2016-01-26 13:48 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-26 13:28 [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Paulo Zanoni
2016-01-26 13:29 ` [PATCH igt 2/6] kms_frontbuffer_tracking: use igt_drm_format_to_bpp() Paulo Zanoni
2016-01-26 13:29 ` [PATCH igt 3/6] kms_frontbuffer_tracking: standardize the used FB sizes Paulo Zanoni
2016-01-26 13:29 ` [PATCH igt 4/6] lib/igt_draw: use igt_drm_format_to_bpp() Paulo Zanoni
2016-01-26 13:29 ` [PATCH igt 5/6] lib/igt_fb: fix igt_get_all_formats documentation Paulo Zanoni
2016-01-26 13:29 ` [PATCH igt 6/6] tests/igt_fb: rename igt_get_all_formats to igt_get_all_cairo_formats Paulo Zanoni
2016-01-26 13:40 ` [PATCH igt 1/6] lib/igt_fb: make the automatic buffer sizes/strides smaller Chris Wilson
2016-01-26 13:48   ` Paulo Zanoni

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.