All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t 1/3] docs: various documentation fixes
@ 2015-05-14 16:04 Thomas Wood
  2015-05-14 16:04 ` [PATCH i-g-t 2/3] igt.cocci: don't use igt_assert_neq to compare pointers Thomas Wood
  2015-05-14 16:04 ` [PATCH i-g-t 3/3] tests: match gem_create prototype in igt_eviction_test_ops create function Thomas Wood
  0 siblings, 2 replies; 3+ messages in thread
From: Thomas Wood @ 2015-05-14 16:04 UTC (permalink / raw)
  To: intel-gfx

Fix various typos, add missing parameter documentation, include the
igt_draw section and update the list of ignored headers.

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
---
 docs/reference/intel-gpu-tools/Makefile.am              |  3 ++-
 docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml |  1 +
 lib/igt_draw.c                                          | 12 ++++++++++++
 lib/igt_draw.h                                          |  4 ++--
 lib/igt_kms.c                                           |  8 +++++---
 5 files changed, 22 insertions(+), 6 deletions(-)

diff --git a/docs/reference/intel-gpu-tools/Makefile.am b/docs/reference/intel-gpu-tools/Makefile.am
index 8364247..0363014 100644
--- a/docs/reference/intel-gpu-tools/Makefile.am
+++ b/docs/reference/intel-gpu-tools/Makefile.am
@@ -126,7 +126,8 @@ EXTRA_HFILES=
 # e.g. IGNORE_HFILES=gtkdebug.h gtkintl.h private_code
 IGNORE_HFILES=gen6_render.h gen7_media.h gen7_render.h gen8_media.h \
 	      gen8_render.h i830_reg.h i915_3d.h i915_pciids.h i915_reg.h \
-	      intel_reg.h debug.h instdone.h media_fill.h rendercopy.h
+	      intel_reg.h debug.h instdone.h media_fill.h rendercopy.h \
+	      media_spin.h media_fill_gen9.h gen9_render.h version.h
 
 # Images to copy into HTML directory.
 # e.g. HTML_IMAGES=$(top_srcdir)/gtk/stock-icons/stock_about_24.png
diff --git a/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml b/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml
index 6c953fd..a6d1f89 100644
--- a/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml
+++ b/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml
@@ -18,6 +18,7 @@
     <xi:include href="xml/drmtest.xml"/>
     <xi:include href="xml/igt_core.xml"/>
     <xi:include href="xml/igt_debugfs.xml"/>
+    <xi:include href="xml/igt_draw.xml"/>
     <xi:include href="xml/igt_kms.xml"/>
     <xi:include href="xml/igt_fb.xml"/>
     <xi:include href="xml/igt_aux.xml"/>
diff --git a/lib/igt_draw.c b/lib/igt_draw.c
index 14e470f..51dce4b 100644
--- a/lib/igt_draw.c
+++ b/lib/igt_draw.c
@@ -68,6 +68,7 @@ struct rect {
 
 /**
  * igt_draw_get_method_name:
+ * @method: draw method
  *
  * Simple function to transform the enum into a string. Useful when naming
  * subtests and printing debug messages.
@@ -533,6 +534,17 @@ void igt_draw_rect(int fd, drm_intel_bufmgr *bufmgr, drm_intel_context *context,
 
 /**
  * igt_draw_rect_fb:
+ * @fd: the DRM file descriptor
+ * @bufmgr: the libdrm bufmgr, only required for IGT_DRAW_BLT and
+ *          IGT_DRAW_RENDER
+ * @context: the context, can be NULL if you don't want to think about it
+ * @fb: framebuffer
+ * @method: method you're going to use to write to the buffer
+ * @rect_x: horizontal position on the buffer where your rectangle starts
+ * @rect_y: vertical position on the buffer where your rectangle starts
+ * @rect_w: width of the rectangle
+ * @rect_h: height of the rectangle
+ * @color: color of the rectangle
  *
  * This is exactly the same as igt_draw_rect, but you can pass an igt_fb instead
  * of manually providing its details. See igt_draw_rect.
diff --git a/lib/igt_draw.h b/lib/igt_draw.h
index 61ffad5..9d8413a 100644
--- a/lib/igt_draw.h
+++ b/lib/igt_draw.h
@@ -29,10 +29,10 @@
 #include "igt_fb.h"
 
 /**
- *igt_draw_method:
+ * igt_draw_method:
  * @IGT_DRAW_MMAP_CPU: draw using a CPU mmap.
  * @IGT_DRAW_MMAP_GTT: draw using a GTT mmap.
- * @IGT-DRAW_MMAP_WC: draw using the WC mmap.
+ * @IGT_DRAW_MMAP_WC: draw using the WC mmap.
  * @IGT_DRAW_PWRITE: draw using the pwrite ioctl.
  * @IGT_DRAW_BLT: draw using the BLT ring.
  * @IGT_DRAW_RENDER: draw using the render ring.
diff --git a/lib/igt_kms.c b/lib/igt_kms.c
index 0665d70..f5670e0 100644
--- a/lib/igt_kms.c
+++ b/lib/igt_kms.c
@@ -1824,11 +1824,12 @@ void igt_plane_set_size(igt_plane_t *plane, int w, int h)
 /**
  * igt_fb_set_position:
  * @fb: framebuffer pointer
+ * @plane: plane
  * @x: X position
  * @y: Y position
  *
  * This function sets position for requested framebuffer as src to plane.
- * New position will be commited at plane commit time via drmModeSetPlane().
+ * New position will be committed at plane commit time via drmModeSetPlane().
  */
 void igt_fb_set_position(struct igt_fb *fb, igt_plane_t *plane,
 	uint32_t x, uint32_t y)
@@ -1846,13 +1847,14 @@ void igt_fb_set_position(struct igt_fb *fb, igt_plane_t *plane,
 }
 
 /**
- * igt_fb_set_position:
+ * igt_fb_set_size:
  * @fb: framebuffer pointer
+ * @plane: plane
  * @w: width
  * @h: height
  *
  * This function sets fetch rect size from requested framebuffer as src
- * to plane. New size will be commited at plane commit time via
+ * to plane. New size will be committed at plane commit time via
  * drmModeSetPlane().
  */
 void igt_fb_set_size(struct igt_fb *fb, igt_plane_t *plane,
-- 
2.1.0

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

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

* [PATCH i-g-t 2/3] igt.cocci: don't use igt_assert_neq to compare pointers
  2015-05-14 16:04 [PATCH i-g-t 1/3] docs: various documentation fixes Thomas Wood
@ 2015-05-14 16:04 ` Thomas Wood
  2015-05-14 16:04 ` [PATCH i-g-t 3/3] tests: match gem_create prototype in igt_eviction_test_ops create function Thomas Wood
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Wood @ 2015-05-14 16:04 UTC (permalink / raw)
  To: intel-gfx

igt_assert_neq can only compare integers, not pointers.

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
---
 lib/igt.cocci     | 2 +-
 tests/prime_udl.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/igt.cocci b/lib/igt.cocci
index f23b511..3aee72f 100644
--- a/lib/igt.cocci
+++ b/lib/igt.cocci
@@ -193,7 +193,7 @@ expression ptr, size, nmemb, stream;
 expression list E;
 @@
 -fgets(E);
-+igt_assert_neq(fgets(E), NULL);
++igt_assert(fgets(E) != NULL);
 
 @@
 identifier func =~ "^v?asprintf$";
diff --git a/tests/prime_udl.c b/tests/prime_udl.c
index d03aee0..b742f1c 100644
--- a/tests/prime_udl.c
+++ b/tests/prime_udl.c
@@ -61,7 +61,7 @@ static int find_and_open_devices(void)
 		if (!fl)
 			break;
 
-		igt_assert_neq(fgets(vendor_id, 8, fl), NULL);
+		igt_assert(fgets(vendor_id, 8, fl) != NULL);
 		fclose(fl);
 
 		venid = strtoul(vendor_id, NULL, 16);
-- 
2.1.0

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

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

* [PATCH i-g-t 3/3] tests: match gem_create prototype in igt_eviction_test_ops create function
  2015-05-14 16:04 [PATCH i-g-t 1/3] docs: various documentation fixes Thomas Wood
  2015-05-14 16:04 ` [PATCH i-g-t 2/3] igt.cocci: don't use igt_assert_neq to compare pointers Thomas Wood
@ 2015-05-14 16:04 ` Thomas Wood
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Wood @ 2015-05-14 16:04 UTC (permalink / raw)
  To: intel-gfx

This avoids a warning when using gem_create as the create function.

Signed-off-by: Thomas Wood <thomas.wood@intel.com>
---
 tests/eviction_common.c   | 2 +-
 tests/gem_userptr_blits.c | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/tests/eviction_common.c b/tests/eviction_common.c
index 6f2f194..91c5acf 100644
--- a/tests/eviction_common.c
+++ b/tests/eviction_common.c
@@ -34,7 +34,7 @@
 
 struct igt_eviction_test_ops
 {
-	uint32_t (*create)(int fd, int size);
+	uint32_t (*create)(int fd, uint64_t size);
 	void (*flink)(uint32_t old_handle, uint32_t new_handle);
 	void	 (*close)(int fd, uint32_t bo);
 	int	 (*copy)(int fd, uint32_t dst, uint32_t src,
diff --git a/tests/gem_userptr_blits.c b/tests/gem_userptr_blits.c
index 41d5769..1f2cc96 100644
--- a/tests/gem_userptr_blits.c
+++ b/tests/gem_userptr_blits.c
@@ -362,7 +362,7 @@ static void free_handle_ptr(uint32_t handle)
 	handle_ptr_map[handle] = NULL;
 }
 
-static uint32_t create_userptr_bo(int fd, int size)
+static uint32_t create_userptr_bo(int fd, uint64_t size)
 {
 	void *ptr;
 	uint32_t handle;
-- 
2.1.0

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

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

end of thread, other threads:[~2015-05-14 16:04 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-14 16:04 [PATCH i-g-t 1/3] docs: various documentation fixes Thomas Wood
2015-05-14 16:04 ` [PATCH i-g-t 2/3] igt.cocci: don't use igt_assert_neq to compare pointers Thomas Wood
2015-05-14 16:04 ` [PATCH i-g-t 3/3] tests: match gem_create prototype in igt_eviction_test_ops create function Thomas Wood

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.