All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments
@ 2017-11-26 19:42 Daniel Vetter
  2017-11-26 19:42 ` [PATCH i-g-t 2/4] docs: remove version information Daniel Vetter
                   ` (7 more replies)
  0 siblings, 8 replies; 12+ messages in thread
From: Daniel Vetter @ 2017-11-26 19:42 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

For reasons entirely not clear to me meson gtkdoc runs in strict
xml parsing mode, whereas automake gtkdoc doesn't. And gtkdoc itself
is tooooooooo dense to correctly escape this stuff.

Paper around this.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 lib/igt_aux.c     | 4 ++--
 lib/igt_core.c    | 4 ++--
 lib/igt_debugfs.c | 2 +-
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/lib/igt_aux.c b/lib/igt_aux.c
index 0bcf792c64e9..62b30ce0e01b 100644
--- a/lib/igt_aux.c
+++ b/lib/igt_aux.c
@@ -1000,7 +1000,7 @@ void igt_drop_root(void)
  * @var: var lookup to to enable this wait
  *
  * Waits for a key press when run interactively and when the corresponding debug
- * var is set in the --interactive-debug=<var> variable. Multiple keys
+ * var is set in the --interactive-debug=$var variable. Multiple keys
  * can be specified as a comma-separated list or alternatively "all" if a wait
  * should happen for all cases.
  *
@@ -1041,7 +1041,7 @@ void igt_debug_wait_for_keypress(const char *var)
  * @expected: message to be printed as expected behaviour before wait for keys Y/n
  *
  * Waits for a key press when run interactively and when the corresponding debug
- * var is set in the --interactive-debug=<var> variable. Multiple vars
+ * var is set in the --interactive-debug=$var variable. Multiple vars
  * can be specified as a comma-separated list or alternatively "all" if a wait
  * should happen for all cases.
  *
diff --git a/lib/igt_core.c b/lib/igt_core.c
index 4fe48c974ef3..b38498e9d13b 100644
--- a/lib/igt_core.c
+++ b/lib/igt_core.c
@@ -164,10 +164,10 @@
  *   test logic.
  *
  * - When adding a new feature test function which uses igt_skip() internally,
- *   use the <prefix>_require_<feature_name> naming scheme. When you
+ *   use the &lt;prefix>_require_&lt;feature_name> naming scheme. When you
  *   instead add a feature test function which returns a boolean, because your
  *   main test logic must take different actions depending upon the feature's
- *   availability, then instead use the <prefix>_has_<feature_name>.
+ *   availability, then instead use the &lt;prefix>_has_&lt;feature_name>.
  *
  * - As already mentioned eschew explicit error handling logic as much as
  *   possible. If your test absolutely has to handle the error of some function
diff --git a/lib/igt_debugfs.c b/lib/igt_debugfs.c
index 5670099f1480..156c1d45ef58 100644
--- a/lib/igt_debugfs.c
+++ b/lib/igt_debugfs.c
@@ -231,7 +231,7 @@ int igt_debugfs_dir(int device)
  * @mode: mode bits as used by open()
  *
  * This opens a debugfs file as a Unix file descriptor. The filename should be
- * relative to the drm device's root, i.e. without "drm/<minor>".
+ * relative to the drm device's root, i.e. without "drm/$minor".
  *
  * Returns:
  * The Unix file descriptor for the debugfs file or -1 if that didn't work out.
-- 
2.15.0

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

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

* [PATCH i-g-t 2/4] docs: remove version information
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
@ 2017-11-26 19:42 ` Daniel Vetter
  2017-11-26 19:42 ` [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef Daniel Vetter
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Daniel Vetter @ 2017-11-26 19:42 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

I haven't figured out how to make this work with meson's gtkdoc
support.

But then all the docs are for the internal library and the tests, and
for that the version information isn't really all that useful. You
just want whatever matches your sourcecode really.

So let's go the easy way and just remove it.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml | 3 ---
 1 file changed, 3 deletions(-)

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 8d77cecd4b02..59163c080048 100644
--- a/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml
+++ b/docs/reference/intel-gpu-tools/intel-gpu-tools-docs.xml
@@ -8,9 +8,6 @@
 <book id="index">
   <bookinfo>
     <title>intel-gpu-tools Reference Manual</title>
-    <releaseinfo>
-      for intel-gpu-tools &version;.
-    </releaseinfo>
   </bookinfo>
 
   <chapter>
-- 
2.15.0

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

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

* [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
  2017-11-26 19:42 ` [PATCH i-g-t 2/4] docs: remove version information Daniel Vetter
@ 2017-11-26 19:42 ` Daniel Vetter
  2017-11-27  8:33   ` Tvrtko Ursulin
  2017-11-26 19:42 ` [PATCH i-g-t 4/4] meson: gtkdoc support Daniel Vetter
                   ` (5 subsequent siblings)
  7 siblings, 1 reply; 12+ messages in thread
From: Daniel Vetter @ 2017-11-26 19:42 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

Helps with making it compile everywhere. This fixes:

commit db31e3c1ca0953b6e6832c25060acd01012a66dd
Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Date:   Wed Nov 8 12:06:52 2017 +0000

    lib/core: Avoid unused result in backtrace printing

(Yes, I don't have libunwind on this machine here. Accidentally)

Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 lib/igt_core.c | 20 ++++++++++----------
 1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/lib/igt_core.c b/lib/igt_core.c
index b38498e9d13b..5f1d1d34dbc6 100644
--- a/lib/igt_core.c
+++ b/lib/igt_core.c
@@ -1231,6 +1231,16 @@ static bool run_under_gdb(void)
 		strncmp(basename(buf), "gdb", 3) == 0);
 }
 
+static void __write_stderr(const char *str, size_t len)
+{
+	igt_ignore_warn(write(STDERR_FILENO, str, len));
+}
+
+static void write_stderr(const char *str)
+{
+	__write_stderr(str, strlen(str));
+}
+
 #ifdef HAVE_LIBUNWIND
 #define UNW_LOCAL_ONLY
 #include <libunwind.h>
@@ -1407,16 +1417,6 @@ xprintf(const char *fmt, ...)
 	va_end(ap);
 }
 
-static void __write_stderr(const char *str, size_t len)
-{
-	igt_ignore_warn(write(STDERR_FILENO, str, len));
-}
-
-static void write_stderr(const char *str)
-{
-	__write_stderr(str, strlen(str));
-}
-
 static void print_backtrace_sig_safe(void)
 {
 	unw_cursor_t cursor;
-- 
2.15.0

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

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

* [PATCH i-g-t 4/4] meson: gtkdoc support
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
  2017-11-26 19:42 ` [PATCH i-g-t 2/4] docs: remove version information Daniel Vetter
  2017-11-26 19:42 ` [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef Daniel Vetter
@ 2017-11-26 19:42 ` Daniel Vetter
  2017-11-26 19:57   ` [PATCH i-g-t] " Daniel Vetter
  2017-11-27  7:59   ` Daniel Vetter
  2017-11-26 20:01 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments Patchwork
                   ` (4 subsequent siblings)
  7 siblings, 2 replies; 12+ messages in thread
From: Daniel Vetter @ 2017-11-26 19:42 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

Bunch of neat improvements:

- xml generates correctly depend upon the test binaries
- no need to re-run autogen.sh when new chapters/functions get added,
  all handed by meson

Still one issue:

- the gtkdoc target doesn't depend upon the custom_target yet, hacked
  around using build_by_default: true

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 docs/meson.build                                   |  1 +
 .../intel-gpu-tools/generate_description_xml.sh    | 44 +++++++++++++
 .../intel-gpu-tools/generate_programs_xml.sh       | 22 +++++++
 docs/reference/intel-gpu-tools/meson.build         | 76 ++++++++++++++++++++++
 docs/reference/meson.build                         |  1 +
 meson.build                                        |  3 +
 meson.sh                                           |  2 +-
 tests/meson.build                                  |  6 +-
 8 files changed, 153 insertions(+), 2 deletions(-)
 create mode 100644 docs/meson.build
 create mode 100644 docs/reference/intel-gpu-tools/generate_description_xml.sh
 create mode 100755 docs/reference/intel-gpu-tools/generate_programs_xml.sh
 create mode 100644 docs/reference/intel-gpu-tools/meson.build
 create mode 100644 docs/reference/meson.build

diff --git a/docs/meson.build b/docs/meson.build
new file mode 100644
index 000000000000..ead14c4015d9
--- /dev/null
+++ b/docs/meson.build
@@ -0,0 +1 @@
+subdir('reference')
diff --git a/docs/reference/intel-gpu-tools/generate_description_xml.sh b/docs/reference/intel-gpu-tools/generate_description_xml.sh
new file mode 100644
index 000000000000..8e39e0c4c289
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_description_xml.sh
@@ -0,0 +1,44 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+testdir=$(dirname $testlist)
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Description</title>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<refsect2 id=\"$test\"><title>" >> $output;
+	echo "$test" | perl -pe 's/(?<=_)$(KEYWORDS)(?=(_|\W))/<acronym>\1<\/acronym>/g' >> $output;
+	echo "</title><para><![CDATA[" >> $output;
+	testprog=$testdir/$test;
+	 ./$testprog --help-description >> $output;
+	echo "]]></para>" >> $output;
+	if ./$testprog --list-subtests > /dev/null ; then
+		echo "<refsect3><title>Subtests</title>" >> $output;
+		subtest_list=`./$testprog --list-subtests`;
+		subtest_count=`echo $subtest_list | wc -w`;
+		if [ $subtest_count -gt 100 ]; then
+			echo "<para>This test has over 100 subtests. " >> $output;
+			echo "Run <command>$test</command> <option>--list-subtests</option> to list them.</para>" >> $output;
+		else
+			echo "<simplelist>" >> $output;
+			for subtest in $subtest_list; do
+				echo "<member>" >> $output;
+				echo "$subtest" | perl -pe 's/\b$(KEYWORDS)\b/<acronym>\1<\/acronym>/g' >> $output;
+				echo "</member>" >> $output;
+			done;
+			echo "</simplelist>" >> $output;
+		fi;
+		echo "</refsect3>" >> $output;
+	fi;
+	echo "</refsect2>" >> $output;
+done;
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/generate_programs_xml.sh b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
new file mode 100755
index 000000000000..73adc8cc7bfc
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Programs</title>" >> $output
+echo "<informaltable pgwide=\"1\" frame=\"none\"><tgroup cols=\"2\"><tbody>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<row><entry role=\"program_name\">" >> $output;
+	echo "<link linkend=\"$test\">$test</link></entry></row>" >> $output;
+done;
+echo "</tbody></tgroup></informaltable>" >> $output
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/meson.build b/docs/reference/intel-gpu-tools/meson.build
new file mode 100644
index 000000000000..38feff3bee5e
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/meson.build
@@ -0,0 +1,76 @@
+gnome = import('gnome')
+
+ignore_headers = [
+	'gen6_render.h',
+	'gen7_media.h',
+	'gen7_render.h',
+	'gen8_media.h',
+	'gen8_render.h',
+	'gpgpu_fill.h',
+	'i830_reg.h',
+	'i915_3d.h',
+	'i915_pciids.h',
+	'i915_reg.h',
+	'igt_edid_template.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',
+]
+
+test_groups = [
+	'amdgpu',
+	'chamelium',
+	'core',
+	'debugfs',
+	'drm',
+	'drv',
+	'gem',
+	'gen3',
+	'gen7',
+	'gvt',
+	'kms',
+	'meta',
+	'perf',
+	'pm',
+	'prime',
+	'sw_sync',
+	'testdisplay',
+	'tools',
+	'vgem',
+]
+
+gen_description = find_program('generate_description_xml.sh')
+gen_programs = find_program('generate_programs_xml.sh')
+
+test_list_files = []
+
+foreach group : test_groups
+	programs_xml = 'igt_test_programs_' + group + '_programs.xml'
+	custom_target(programs_xml,
+		      output : programs_xml,
+		      build_by_default : true,
+		      command : [ gen_programs, '@OUTPUT@', group, test_list ])
+
+	description_xml = 'igt_test_programs_' + group + '_description.xml'
+	custom_target(description_xml,
+		      output : description_xml,
+		      build_by_default : true,
+		      depends : test_executables,
+		      command : [ gen_description, '@OUTPUT@', group, test_list ])
+endforeach
+
+gnome.gtkdoc('intel-gpu-tools',
+	     content_files : ['igt_test_programs.xml'],
+	     dependencies : lib_igt,
+	     install : true,
+	     main_xml : 'intel-gpu-tools-docs.xml',
+	     scan_args : '--rebuild-sections',
+	     mkdb_args : '--output-format=xml',
+	     ignore_headers : ignore_headers,
+	     src_dir : inc_for_gtkdoc)
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
new file mode 100644
index 000000000000..944f28a5615e
--- /dev/null
+++ b/docs/reference/meson.build
@@ -0,0 +1 @@
+subdir('intel-gpu-tools')
diff --git a/meson.build b/meson.build
index 2361866b32d2..e3fb0cd5ed61 100644
--- a/meson.build
+++ b/meson.build
@@ -28,6 +28,8 @@ endforeach
 
 inc = include_directories('include/drm-uapi', 'lib', '.')
 
+inc_for_gtkdoc = include_directories('lib')
+
 config = configuration_data()
 
 libdrm = dependency('libdrm', version : '>=2.4.82')
@@ -139,3 +141,4 @@ if libdrm_intel.found()
 	endif
 endif
 subdir('man')
+subdir('docs')
diff --git a/meson.sh b/meson.sh
index cbf1a9326dbe..ae8e3488d962 100755
--- a/meson.sh
+++ b/meson.sh
@@ -28,7 +28,7 @@ install uninstall:
 	echo "meson install support not yet completed" && false
 
 docs:
-	echo "meson gtkdoc support not yet completed" && false
+	ninja -C build intel-gpu-tools-doc
 
 EOF
 
diff --git a/tests/meson.build b/tests/meson.build
index 9030cf0d1b5e..5555d5886164 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -261,12 +261,14 @@ endif
 
 libexecdir = join_paths(get_option('prefix'), get_option('libexecdir'), 'intel-gpu-tools')
 
+test_executables = []
+
 foreach prog : test_progs
 	link = []
 	if prog == 'perf_pmu'
 		link += lib_igt_perf
 	endif
-	executable(prog, prog + '.c',
+	test_executables += executable(prog, prog + '.c',
 		   dependencies : test_deps,
 		   install_dir : libexecdir,
 		   link_with : link,
@@ -288,6 +290,8 @@ custom_target('testlist',
 	      install : true,
 	      install_dir : pkgdatadir)
 
+test_list = files('test-list.txt')
+
 test_script = find_program('igt_command_line.sh')
 foreach prog : test_progs
 	test('testcase check: ' + prog, test_script,
-- 
2.15.0

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

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

* [PATCH i-g-t] meson: gtkdoc support
  2017-11-26 19:42 ` [PATCH i-g-t 4/4] meson: gtkdoc support Daniel Vetter
@ 2017-11-26 19:57   ` Daniel Vetter
  2017-11-27  7:59   ` Daniel Vetter
  1 sibling, 0 replies; 12+ messages in thread
From: Daniel Vetter @ 2017-11-26 19:57 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

Bunch of neat improvements:

- xml generates correctly depend upon the test binaries
- no need to re-run autogen.sh when new chapters/functions get added,
  all handed by meson

Still one issue:

- the gtkdoc target doesn't depend upon the custom_target yet, hacked
  around using build_by_default: true

v2: Bump meson version to 0.42, since that's the first release which
adds the build dir when running the gtkdoc tools, and hence allows
including generated files.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 docs/meson.build                                   |  1 +
 .../intel-gpu-tools/generate_description_xml.sh    | 44 +++++++++++++
 .../intel-gpu-tools/generate_programs_xml.sh       | 22 +++++++
 docs/reference/intel-gpu-tools/meson.build         | 76 ++++++++++++++++++++++
 docs/reference/meson.build                         |  1 +
 meson.build                                        |  5 +-
 meson.sh                                           |  2 +-
 tests/meson.build                                  |  6 +-
 8 files changed, 154 insertions(+), 3 deletions(-)
 create mode 100644 docs/meson.build
 create mode 100644 docs/reference/intel-gpu-tools/generate_description_xml.sh
 create mode 100755 docs/reference/intel-gpu-tools/generate_programs_xml.sh
 create mode 100644 docs/reference/intel-gpu-tools/meson.build
 create mode 100644 docs/reference/meson.build

diff --git a/docs/meson.build b/docs/meson.build
new file mode 100644
index 000000000000..ead14c4015d9
--- /dev/null
+++ b/docs/meson.build
@@ -0,0 +1 @@
+subdir('reference')
diff --git a/docs/reference/intel-gpu-tools/generate_description_xml.sh b/docs/reference/intel-gpu-tools/generate_description_xml.sh
new file mode 100644
index 000000000000..8e39e0c4c289
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_description_xml.sh
@@ -0,0 +1,44 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+testdir=$(dirname $testlist)
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Description</title>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<refsect2 id=\"$test\"><title>" >> $output;
+	echo "$test" | perl -pe 's/(?<=_)$(KEYWORDS)(?=(_|\W))/<acronym>\1<\/acronym>/g' >> $output;
+	echo "</title><para><![CDATA[" >> $output;
+	testprog=$testdir/$test;
+	 ./$testprog --help-description >> $output;
+	echo "]]></para>" >> $output;
+	if ./$testprog --list-subtests > /dev/null ; then
+		echo "<refsect3><title>Subtests</title>" >> $output;
+		subtest_list=`./$testprog --list-subtests`;
+		subtest_count=`echo $subtest_list | wc -w`;
+		if [ $subtest_count -gt 100 ]; then
+			echo "<para>This test has over 100 subtests. " >> $output;
+			echo "Run <command>$test</command> <option>--list-subtests</option> to list them.</para>" >> $output;
+		else
+			echo "<simplelist>" >> $output;
+			for subtest in $subtest_list; do
+				echo "<member>" >> $output;
+				echo "$subtest" | perl -pe 's/\b$(KEYWORDS)\b/<acronym>\1<\/acronym>/g' >> $output;
+				echo "</member>" >> $output;
+			done;
+			echo "</simplelist>" >> $output;
+		fi;
+		echo "</refsect3>" >> $output;
+	fi;
+	echo "</refsect2>" >> $output;
+done;
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/generate_programs_xml.sh b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
new file mode 100755
index 000000000000..73adc8cc7bfc
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Programs</title>" >> $output
+echo "<informaltable pgwide=\"1\" frame=\"none\"><tgroup cols=\"2\"><tbody>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<row><entry role=\"program_name\">" >> $output;
+	echo "<link linkend=\"$test\">$test</link></entry></row>" >> $output;
+done;
+echo "</tbody></tgroup></informaltable>" >> $output
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/meson.build b/docs/reference/intel-gpu-tools/meson.build
new file mode 100644
index 000000000000..38feff3bee5e
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/meson.build
@@ -0,0 +1,76 @@
+gnome = import('gnome')
+
+ignore_headers = [
+	'gen6_render.h',
+	'gen7_media.h',
+	'gen7_render.h',
+	'gen8_media.h',
+	'gen8_render.h',
+	'gpgpu_fill.h',
+	'i830_reg.h',
+	'i915_3d.h',
+	'i915_pciids.h',
+	'i915_reg.h',
+	'igt_edid_template.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',
+]
+
+test_groups = [
+	'amdgpu',
+	'chamelium',
+	'core',
+	'debugfs',
+	'drm',
+	'drv',
+	'gem',
+	'gen3',
+	'gen7',
+	'gvt',
+	'kms',
+	'meta',
+	'perf',
+	'pm',
+	'prime',
+	'sw_sync',
+	'testdisplay',
+	'tools',
+	'vgem',
+]
+
+gen_description = find_program('generate_description_xml.sh')
+gen_programs = find_program('generate_programs_xml.sh')
+
+test_list_files = []
+
+foreach group : test_groups
+	programs_xml = 'igt_test_programs_' + group + '_programs.xml'
+	custom_target(programs_xml,
+		      output : programs_xml,
+		      build_by_default : true,
+		      command : [ gen_programs, '@OUTPUT@', group, test_list ])
+
+	description_xml = 'igt_test_programs_' + group + '_description.xml'
+	custom_target(description_xml,
+		      output : description_xml,
+		      build_by_default : true,
+		      depends : test_executables,
+		      command : [ gen_description, '@OUTPUT@', group, test_list ])
+endforeach
+
+gnome.gtkdoc('intel-gpu-tools',
+	     content_files : ['igt_test_programs.xml'],
+	     dependencies : lib_igt,
+	     install : true,
+	     main_xml : 'intel-gpu-tools-docs.xml',
+	     scan_args : '--rebuild-sections',
+	     mkdb_args : '--output-format=xml',
+	     ignore_headers : ignore_headers,
+	     src_dir : inc_for_gtkdoc)
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
new file mode 100644
index 000000000000..944f28a5615e
--- /dev/null
+++ b/docs/reference/meson.build
@@ -0,0 +1 @@
+subdir('intel-gpu-tools')
diff --git a/meson.build b/meson.build
index 2361866b32d2..fa5d71f797e9 100644
--- a/meson.build
+++ b/meson.build
@@ -5,7 +5,7 @@ project('IGT gpu tests', 'c',
           'c_std=gnu99',
         ],
 	license : 'MIT',
-	meson_version : '>0.40.0')
+	meson_version : '>0.42.0')
 
 cc = meson.get_compiler('c')
 
@@ -28,6 +28,8 @@ endforeach
 
 inc = include_directories('include/drm-uapi', 'lib', '.')
 
+inc_for_gtkdoc = include_directories('lib')
+
 config = configuration_data()
 
 libdrm = dependency('libdrm', version : '>=2.4.82')
@@ -139,3 +141,4 @@ if libdrm_intel.found()
 	endif
 endif
 subdir('man')
+subdir('docs')
diff --git a/meson.sh b/meson.sh
index cbf1a9326dbe..ae8e3488d962 100755
--- a/meson.sh
+++ b/meson.sh
@@ -28,7 +28,7 @@ install uninstall:
 	echo "meson install support not yet completed" && false
 
 docs:
-	echo "meson gtkdoc support not yet completed" && false
+	ninja -C build intel-gpu-tools-doc
 
 EOF
 
diff --git a/tests/meson.build b/tests/meson.build
index 9030cf0d1b5e..5555d5886164 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -261,12 +261,14 @@ endif
 
 libexecdir = join_paths(get_option('prefix'), get_option('libexecdir'), 'intel-gpu-tools')
 
+test_executables = []
+
 foreach prog : test_progs
 	link = []
 	if prog == 'perf_pmu'
 		link += lib_igt_perf
 	endif
-	executable(prog, prog + '.c',
+	test_executables += executable(prog, prog + '.c',
 		   dependencies : test_deps,
 		   install_dir : libexecdir,
 		   link_with : link,
@@ -288,6 +290,8 @@ custom_target('testlist',
 	      install : true,
 	      install_dir : pkgdatadir)
 
+test_list = files('test-list.txt')
+
 test_script = find_program('igt_command_line.sh')
 foreach prog : test_progs
 	test('testcase check: ' + prog, test_script,
-- 
2.15.0

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

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

* ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
                   ` (2 preceding siblings ...)
  2017-11-26 19:42 ` [PATCH i-g-t 4/4] meson: gtkdoc support Daniel Vetter
@ 2017-11-26 20:01 ` Patchwork
  2017-11-26 20:42 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev2) Patchwork
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2017-11-26 20:01 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx

== Series Details ==

Series: series starting with [1/4] lib: avoid < in gtkdoc comments
URL   : https://patchwork.freedesktop.org/series/34413/
State : success

== Summary ==

IGT patchset tested on top of latest successful build
4c57ff468fa48707777184b3da56432602f967af intel/pmu: Catch-up with i915 RC6 aggregation changes

with latest DRM-Tip kernel build CI_DRM_3391
27988345458b drm-tip: 2017y-11m-26d-16h-20m-22s UTC integration manifest

No testlist changes.

Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-b:
                incomplete -> PASS       (fi-snb-2520m) fdo#103713
Test drv_module_reload:
        Subgroup basic-reload-inject:
                dmesg-warn -> PASS       (fi-bwr-2160)

fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713

fi-bdw-5557u     total:289  pass:268  dwarn:0   dfail:0   fail:0   skip:21  time:441s
fi-bdw-gvtdvm    total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:458s
fi-blb-e6850     total:289  pass:223  dwarn:1   dfail:0   fail:0   skip:65  time:383s
fi-bsw-n3050     total:289  pass:243  dwarn:0   dfail:0   fail:0   skip:46  time:536s
fi-bwr-2160      total:289  pass:183  dwarn:0   dfail:0   fail:0   skip:106 time:278s
fi-bxt-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:508s
fi-bxt-j4205     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:511s
fi-byt-j1900     total:289  pass:254  dwarn:0   dfail:0   fail:0   skip:35  time:492s
fi-byt-n2820     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:486s
fi-elk-e7500     total:289  pass:229  dwarn:0   dfail:0   fail:0   skip:60  time:425s
fi-gdg-551       total:289  pass:178  dwarn:1   dfail:0   fail:1   skip:109 time:266s
fi-glk-1         total:289  pass:261  dwarn:0   dfail:0   fail:0   skip:28  time:540s
fi-hsw-4770      total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:431s
fi-hsw-4770r     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:435s
fi-ilk-650       total:289  pass:228  dwarn:0   dfail:0   fail:0   skip:61  time:426s
fi-ivb-3520m     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:481s
fi-ivb-3770      total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:464s
fi-kbl-7500u     total:289  pass:264  dwarn:1   dfail:0   fail:0   skip:24  time:485s
fi-kbl-7560u     total:289  pass:270  dwarn:0   dfail:0   fail:0   skip:19  time:528s
fi-kbl-7567u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:479s
fi-kbl-r         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:529s
fi-pnv-d510      total:289  pass:222  dwarn:1   dfail:0   fail:0   skip:66  time:569s
fi-skl-6260u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:454s
fi-skl-6600u     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:544s
fi-skl-6700hq    total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:567s
fi-skl-6700k     total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:513s
fi-skl-6770hq    total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:498s
fi-skl-gvtdvm    total:289  pass:266  dwarn:0   dfail:0   fail:0   skip:23  time:453s
fi-snb-2520m     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:554s
fi-snb-2600      total:289  pass:249  dwarn:0   dfail:0   fail:0   skip:40  time:421s
Blacklisted hosts:
fi-cfl-s2        total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:614s
fi-cnl-y         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:573s
fi-glk-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:495s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_551/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev2)
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
                   ` (3 preceding siblings ...)
  2017-11-26 20:01 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments Patchwork
@ 2017-11-26 20:42 ` Patchwork
  2017-11-26 21:49 ` ✗ Fi.CI.IGT: warning " Patchwork
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2017-11-26 20:42 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx

== Series Details ==

Series: series starting with [1/4] lib: avoid < in gtkdoc comments (rev2)
URL   : https://patchwork.freedesktop.org/series/34413/
State : success

== Summary ==

IGT patchset tested on top of latest successful build
4c57ff468fa48707777184b3da56432602f967af intel/pmu: Catch-up with i915 RC6 aggregation changes

with latest DRM-Tip kernel build CI_DRM_3392
2ac27dcb0eb2 drm-tip: 2017y-11m-26d-19h-47m-14s UTC integration manifest

No testlist changes.

Test kms_pipe_crc_basic:
        Subgroup suspend-read-crc-pipe-b:
                pass       -> INCOMPLETE (fi-snb-2520m) fdo#103713

fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713

fi-bdw-5557u     total:289  pass:268  dwarn:0   dfail:0   fail:0   skip:21  time:440s
fi-bdw-gvtdvm    total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:453s
fi-blb-e6850     total:289  pass:223  dwarn:1   dfail:0   fail:0   skip:65  time:380s
fi-bsw-n3050     total:289  pass:243  dwarn:0   dfail:0   fail:0   skip:46  time:544s
fi-bwr-2160      total:289  pass:183  dwarn:0   dfail:0   fail:0   skip:106 time:278s
fi-bxt-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:516s
fi-bxt-j4205     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:511s
fi-byt-j1900     total:289  pass:254  dwarn:0   dfail:0   fail:0   skip:35  time:489s
fi-byt-n2820     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:484s
fi-elk-e7500     total:289  pass:229  dwarn:0   dfail:0   fail:0   skip:60  time:427s
fi-gdg-551       total:289  pass:178  dwarn:1   dfail:0   fail:1   skip:109 time:268s
fi-glk-1         total:289  pass:261  dwarn:0   dfail:0   fail:0   skip:28  time:541s
fi-hsw-4770      total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:426s
fi-hsw-4770r     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:438s
fi-ilk-650       total:289  pass:228  dwarn:0   dfail:0   fail:0   skip:61  time:441s
fi-ivb-3520m     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:483s
fi-ivb-3770      total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:459s
fi-kbl-7500u     total:289  pass:264  dwarn:1   dfail:0   fail:0   skip:24  time:481s
fi-kbl-7560u     total:289  pass:270  dwarn:0   dfail:0   fail:0   skip:19  time:537s
fi-kbl-7567u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:478s
fi-kbl-r         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:527s
fi-pnv-d510      total:289  pass:222  dwarn:1   dfail:0   fail:0   skip:66  time:566s
fi-skl-6260u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:462s
fi-skl-6600u     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:541s
fi-skl-6700hq    total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:570s
fi-skl-6700k     total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:514s
fi-skl-6770hq    total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:498s
fi-skl-gvtdvm    total:289  pass:266  dwarn:0   dfail:0   fail:0   skip:23  time:461s
fi-snb-2520m     total:246  pass:212  dwarn:0   dfail:0   fail:0   skip:33 
fi-snb-2600      total:289  pass:249  dwarn:0   dfail:0   fail:0   skip:40  time:421s
Blacklisted hosts:
fi-cfl-s2        total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:614s
fi-glk-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:496s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_552/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* ✗ Fi.CI.IGT: warning for series starting with [1/4] lib: avoid < in gtkdoc comments (rev2)
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
                   ` (4 preceding siblings ...)
  2017-11-26 20:42 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev2) Patchwork
@ 2017-11-26 21:49 ` Patchwork
  2017-11-27  8:17 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev3) Patchwork
  2017-11-27  9:04 ` ✗ Fi.CI.IGT: warning " Patchwork
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2017-11-26 21:49 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx

== Series Details ==

Series: series starting with [1/4] lib: avoid < in gtkdoc comments (rev2)
URL   : https://patchwork.freedesktop.org/series/34413/
State : warning

== Summary ==

Test kms_frontbuffer_tracking:
        Subgroup fbc-1p-offscren-pri-shrfb-draw-blt:
                pass       -> FAIL       (shard-snb) fdo#101623 +1
        Subgroup fbc-1p-primscrn-spr-indfb-draw-blt:
                pass       -> SKIP       (shard-hsw)
Test kms_draw_crc:
        Subgroup draw-method-xrgb8888-mmap-wc-untiled:
                pass       -> SKIP       (shard-hsw) fdo#103184
Test kms_flip:
        Subgroup wf_vblank-vs-modeset-interruptible:
                pass       -> SKIP       (shard-hsw) fdo#102614
        Subgroup flip-vs-expired-vblank-interruptible:
                fail       -> PASS       (shard-hsw) fdo#102887
Test kms_cursor_crc:
        Subgroup cursor-256x256-onscreen:
                pass       -> SKIP       (shard-hsw)
Test kms_atomic:
        Subgroup plane_invalid_params:
                pass       -> SKIP       (shard-hsw)
Test perf:
        Subgroup blocking:
                fail       -> PASS       (shard-hsw) fdo#102252 +1
Test gem_busy:
        Subgroup close-race:
                pass       -> FAIL       (shard-snb) fdo#103829
Test drv_selftest:
        Subgroup mock_sanitycheck:
                dmesg-warn -> PASS       (shard-snb) fdo#103717
Test drv_module_reload:
        Subgroup basic-no-display:
                dmesg-warn -> PASS       (shard-snb) fdo#102707
Test kms_setmode:
        Subgroup basic:
                fail       -> PASS       (shard-hsw) fdo#99912
Test kms_vblank:
        Subgroup accuracy-idle:
                pass       -> FAIL       (shard-hsw) fdo#102583

fdo#101623 https://bugs.freedesktop.org/show_bug.cgi?id=101623
fdo#103184 https://bugs.freedesktop.org/show_bug.cgi?id=103184
fdo#102614 https://bugs.freedesktop.org/show_bug.cgi?id=102614
fdo#102887 https://bugs.freedesktop.org/show_bug.cgi?id=102887
fdo#102252 https://bugs.freedesktop.org/show_bug.cgi?id=102252
fdo#103829 https://bugs.freedesktop.org/show_bug.cgi?id=103829
fdo#103717 https://bugs.freedesktop.org/show_bug.cgi?id=103717
fdo#102707 https://bugs.freedesktop.org/show_bug.cgi?id=102707
fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912
fdo#102583 https://bugs.freedesktop.org/show_bug.cgi?id=102583

shard-hsw        total:2662 pass:1529 dwarn:1   dfail:0   fail:11  skip:1121 time:9421s
shard-snb        total:2662 pass:1306 dwarn:1   dfail:0   fail:13  skip:1342 time:8061s
Blacklisted hosts:
shard-apl        total:2618 pass:1653 dwarn:3   dfail:0   fail:24  skip:937 time:12876s
shard-kbl        total:2662 pass:1794 dwarn:8   dfail:0   fail:25  skip:835 time:11169s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_552/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* [PATCH i-g-t] meson: gtkdoc support
  2017-11-26 19:42 ` [PATCH i-g-t 4/4] meson: gtkdoc support Daniel Vetter
  2017-11-26 19:57   ` [PATCH i-g-t] " Daniel Vetter
@ 2017-11-27  7:59   ` Daniel Vetter
  1 sibling, 0 replies; 12+ messages in thread
From: Daniel Vetter @ 2017-11-27  7:59 UTC (permalink / raw)
  To: Intel Graphics Development; +Cc: Daniel Vetter

Bunch of neat improvements:

- xml generates correctly depend upon the test binaries
- no need to re-run autogen.sh when new chapters/functions get added,
  all handed by meson

Still one issue:

- the gtkdoc target doesn't depend upon the custom_target yet, hacked
  around using build_by_default: true

v2: Bump meson version to 0.42, since that's the first release which
adds the build dir when running the gtkdoc tools, and hence allows
including generated files.

v2:
- Undo the bump, it's only needed for generated source files. Other
  generated files as input should work with 0.40 already.

- Generate version.xml from version.xml.in, which allows us to keep
  the &version; entity.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
 docs/meson.build                                   |  1 +
 .../intel-gpu-tools/generate_description_xml.sh    | 44 ++++++++++++
 .../intel-gpu-tools/generate_programs_xml.sh       | 22 ++++++
 docs/reference/intel-gpu-tools/meson.build         | 80 ++++++++++++++++++++++
 docs/reference/meson.build                         |  1 +
 meson.build                                        |  3 +
 meson.sh                                           |  2 +-
 tests/meson.build                                  |  6 +-
 8 files changed, 157 insertions(+), 2 deletions(-)
 create mode 100644 docs/meson.build
 create mode 100644 docs/reference/intel-gpu-tools/generate_description_xml.sh
 create mode 100755 docs/reference/intel-gpu-tools/generate_programs_xml.sh
 create mode 100644 docs/reference/intel-gpu-tools/meson.build
 create mode 100644 docs/reference/meson.build

diff --git a/docs/meson.build b/docs/meson.build
new file mode 100644
index 000000000000..ead14c4015d9
--- /dev/null
+++ b/docs/meson.build
@@ -0,0 +1 @@
+subdir('reference')
diff --git a/docs/reference/intel-gpu-tools/generate_description_xml.sh b/docs/reference/intel-gpu-tools/generate_description_xml.sh
new file mode 100644
index 000000000000..8e39e0c4c289
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_description_xml.sh
@@ -0,0 +1,44 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+testdir=$(dirname $testlist)
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Description</title>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<refsect2 id=\"$test\"><title>" >> $output;
+	echo "$test" | perl -pe 's/(?<=_)$(KEYWORDS)(?=(_|\W))/<acronym>\1<\/acronym>/g' >> $output;
+	echo "</title><para><![CDATA[" >> $output;
+	testprog=$testdir/$test;
+	 ./$testprog --help-description >> $output;
+	echo "]]></para>" >> $output;
+	if ./$testprog --list-subtests > /dev/null ; then
+		echo "<refsect3><title>Subtests</title>" >> $output;
+		subtest_list=`./$testprog --list-subtests`;
+		subtest_count=`echo $subtest_list | wc -w`;
+		if [ $subtest_count -gt 100 ]; then
+			echo "<para>This test has over 100 subtests. " >> $output;
+			echo "Run <command>$test</command> <option>--list-subtests</option> to list them.</para>" >> $output;
+		else
+			echo "<simplelist>" >> $output;
+			for subtest in $subtest_list; do
+				echo "<member>" >> $output;
+				echo "$subtest" | perl -pe 's/\b$(KEYWORDS)\b/<acronym>\1<\/acronym>/g' >> $output;
+				echo "</member>" >> $output;
+			done;
+			echo "</simplelist>" >> $output;
+		fi;
+		echo "</refsect3>" >> $output;
+	fi;
+	echo "</refsect2>" >> $output;
+done;
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/generate_programs_xml.sh b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
new file mode 100755
index 000000000000..73adc8cc7bfc
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/generate_programs_xml.sh
@@ -0,0 +1,22 @@
+#!/bin/sh
+
+output=$1
+filter=$2
+testlist=$3
+
+echo "<?xml version=\"1.0\"?>" > $output
+echo "<!DOCTYPE refsect1 PUBLIC \"-//OASIS//DTD DocBook XML V4.3//EN\"" >> $output
+echo "               \"http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd\"" >> $output
+echo "[" >> $output
+echo "  <!ENTITY % local.common.attrib \"xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'\">" >> $output
+echo "  <!ENTITY version SYSTEM \"version.xml\">" >> $output
+echo "]>" >> $output
+echo "<refsect1>" >> $output
+echo "<title>Programs</title>" >> $output
+echo "<informaltable pgwide=\"1\" frame=\"none\"><tgroup cols=\"2\"><tbody>" >> $output
+for test in `cat $testlist | tr ' ' '\n' | grep "^$filter" | sort`; do
+	echo "<row><entry role=\"program_name\">" >> $output;
+	echo "<link linkend=\"$test\">$test</link></entry></row>" >> $output;
+done;
+echo "</tbody></tgroup></informaltable>" >> $output
+echo "</refsect1>" >> $output
diff --git a/docs/reference/intel-gpu-tools/meson.build b/docs/reference/intel-gpu-tools/meson.build
new file mode 100644
index 000000000000..1c009229aae2
--- /dev/null
+++ b/docs/reference/intel-gpu-tools/meson.build
@@ -0,0 +1,80 @@
+gnome = import('gnome')
+
+ignore_headers = [
+	'gen6_render.h',
+	'gen7_media.h',
+	'gen7_render.h',
+	'gen8_media.h',
+	'gen8_render.h',
+	'gpgpu_fill.h',
+	'i830_reg.h',
+	'i915_3d.h',
+	'i915_pciids.h',
+	'i915_reg.h',
+	'igt_edid_template.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',
+]
+
+test_groups = [
+	'amdgpu',
+	'chamelium',
+	'core',
+	'debugfs',
+	'drm',
+	'drv',
+	'gem',
+	'gen3',
+	'gen7',
+	'gvt',
+	'kms',
+	'meta',
+	'perf',
+	'pm',
+	'prime',
+	'sw_sync',
+	'testdisplay',
+	'tools',
+	'vgem',
+]
+
+gen_description = find_program('generate_description_xml.sh')
+gen_programs = find_program('generate_programs_xml.sh')
+
+test_list_files = []
+
+foreach group : test_groups
+	programs_xml = 'igt_test_programs_' + group + '_programs.xml'
+	custom_target(programs_xml,
+		      output : programs_xml,
+		      build_by_default : true,
+		      command : [ gen_programs, '@OUTPUT@', group, test_list ])
+
+	description_xml = 'igt_test_programs_' + group + '_description.xml'
+	custom_target(description_xml,
+		      output : description_xml,
+		      build_by_default : true,
+		      depends : test_executables,
+		      command : [ gen_description, '@OUTPUT@', group, test_list ])
+endforeach
+
+configure_file(input: 'version.xml.in',
+	       output: 'version.xml',
+	       install: false, configuration: config)
+
+gnome.gtkdoc('intel-gpu-tools',
+	     content_files : ['igt_test_programs.xml'],
+	     dependencies : lib_igt,
+	     install : true,
+	     main_xml : 'intel-gpu-tools-docs.xml',
+	     scan_args : '--rebuild-sections',
+	     mkdb_args : '--output-format=xml',
+	     ignore_headers : ignore_headers,
+	     src_dir : inc_for_gtkdoc)
diff --git a/docs/reference/meson.build b/docs/reference/meson.build
new file mode 100644
index 000000000000..944f28a5615e
--- /dev/null
+++ b/docs/reference/meson.build
@@ -0,0 +1 @@
+subdir('intel-gpu-tools')
diff --git a/meson.build b/meson.build
index 2361866b32d2..e3fb0cd5ed61 100644
--- a/meson.build
+++ b/meson.build
@@ -28,6 +28,8 @@ endforeach
 
 inc = include_directories('include/drm-uapi', 'lib', '.')
 
+inc_for_gtkdoc = include_directories('lib')
+
 config = configuration_data()
 
 libdrm = dependency('libdrm', version : '>=2.4.82')
@@ -139,3 +141,4 @@ if libdrm_intel.found()
 	endif
 endif
 subdir('man')
+subdir('docs')
diff --git a/meson.sh b/meson.sh
index cbf1a9326dbe..ae8e3488d962 100755
--- a/meson.sh
+++ b/meson.sh
@@ -28,7 +28,7 @@ install uninstall:
 	echo "meson install support not yet completed" && false
 
 docs:
-	echo "meson gtkdoc support not yet completed" && false
+	ninja -C build intel-gpu-tools-doc
 
 EOF
 
diff --git a/tests/meson.build b/tests/meson.build
index 9030cf0d1b5e..5555d5886164 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -261,12 +261,14 @@ endif
 
 libexecdir = join_paths(get_option('prefix'), get_option('libexecdir'), 'intel-gpu-tools')
 
+test_executables = []
+
 foreach prog : test_progs
 	link = []
 	if prog == 'perf_pmu'
 		link += lib_igt_perf
 	endif
-	executable(prog, prog + '.c',
+	test_executables += executable(prog, prog + '.c',
 		   dependencies : test_deps,
 		   install_dir : libexecdir,
 		   link_with : link,
@@ -288,6 +290,8 @@ custom_target('testlist',
 	      install : true,
 	      install_dir : pkgdatadir)
 
+test_list = files('test-list.txt')
+
 test_script = find_program('igt_command_line.sh')
 foreach prog : test_progs
 	test('testcase check: ' + prog, test_script,
-- 
2.15.0

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

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

* ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev3)
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
                   ` (5 preceding siblings ...)
  2017-11-26 21:49 ` ✗ Fi.CI.IGT: warning " Patchwork
@ 2017-11-27  8:17 ` Patchwork
  2017-11-27  9:04 ` ✗ Fi.CI.IGT: warning " Patchwork
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2017-11-27  8:17 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx

== Series Details ==

Series: series starting with [1/4] lib: avoid < in gtkdoc comments (rev3)
URL   : https://patchwork.freedesktop.org/series/34413/
State : success

== Summary ==

IGT patchset tested on top of latest successful build
4c57ff468fa48707777184b3da56432602f967af intel/pmu: Catch-up with i915 RC6 aggregation changes

with latest DRM-Tip kernel build CI_DRM_3392
2ac27dcb0eb2 drm-tip: 2017y-11m-26d-19h-47m-14s UTC integration manifest

No testlist changes.

fi-bdw-5557u     total:289  pass:268  dwarn:0   dfail:0   fail:0   skip:21  time:442s
fi-bdw-gvtdvm    total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:452s
fi-blb-e6850     total:289  pass:223  dwarn:1   dfail:0   fail:0   skip:65  time:386s
fi-bsw-n3050     total:289  pass:243  dwarn:0   dfail:0   fail:0   skip:46  time:526s
fi-bwr-2160      total:289  pass:183  dwarn:0   dfail:0   fail:0   skip:106 time:278s
fi-bxt-dsi       total:289  pass:259  dwarn:0   dfail:0   fail:0   skip:30  time:510s
fi-bxt-j4205     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:504s
fi-byt-j1900     total:289  pass:254  dwarn:0   dfail:0   fail:0   skip:35  time:493s
fi-byt-n2820     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:486s
fi-elk-e7500     total:289  pass:229  dwarn:0   dfail:0   fail:0   skip:60  time:425s
fi-gdg-551       total:289  pass:178  dwarn:1   dfail:0   fail:1   skip:109 time:266s
fi-glk-1         total:289  pass:261  dwarn:0   dfail:0   fail:0   skip:28  time:545s
fi-hsw-4770      total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:426s
fi-hsw-4770r     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:435s
fi-ilk-650       total:289  pass:228  dwarn:0   dfail:0   fail:0   skip:61  time:430s
fi-ivb-3520m     total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:475s
fi-ivb-3770      total:289  pass:260  dwarn:0   dfail:0   fail:0   skip:29  time:463s
fi-kbl-7500u     total:289  pass:264  dwarn:1   dfail:0   fail:0   skip:24  time:490s
fi-kbl-7560u     total:289  pass:270  dwarn:0   dfail:0   fail:0   skip:19  time:534s
fi-kbl-7567u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:482s
fi-kbl-r         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:533s
fi-pnv-d510      total:289  pass:222  dwarn:1   dfail:0   fail:0   skip:66  time:575s
fi-skl-6260u     total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:451s
fi-skl-6600u     total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:542s
fi-skl-6700hq    total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:570s
fi-skl-6700k     total:289  pass:265  dwarn:0   dfail:0   fail:0   skip:24  time:513s
fi-skl-6770hq    total:289  pass:269  dwarn:0   dfail:0   fail:0   skip:20  time:495s
fi-skl-gvtdvm    total:289  pass:266  dwarn:0   dfail:0   fail:0   skip:23  time:453s
fi-snb-2520m     total:289  pass:250  dwarn:0   dfail:0   fail:0   skip:39  time:556s
fi-snb-2600      total:289  pass:249  dwarn:0   dfail:0   fail:0   skip:40  time:423s
Blacklisted hosts:
fi-cfl-s2        total:289  pass:263  dwarn:0   dfail:0   fail:0   skip:26  time:612s
fi-cnl-y         total:289  pass:262  dwarn:0   dfail:0   fail:0   skip:27  time:557s
fi-glk-dsi       total:118  pass:54   dwarn:0   dfail:1   fail:1   skip:61 

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_553/
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

* Re: [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef
  2017-11-26 19:42 ` [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef Daniel Vetter
@ 2017-11-27  8:33   ` Tvrtko Ursulin
  0 siblings, 0 replies; 12+ messages in thread
From: Tvrtko Ursulin @ 2017-11-27  8:33 UTC (permalink / raw)
  To: Daniel Vetter, Intel Graphics Development


On 26/11/2017 19:42, Daniel Vetter wrote:
> Helps with making it compile everywhere. This fixes:
> 
> commit db31e3c1ca0953b6e6832c25060acd01012a66dd
> Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Date:   Wed Nov 8 12:06:52 2017 +0000
> 
>      lib/core: Avoid unused result in backtrace printing
> 
> (Yes, I don't have libunwind on this machine here. Accidentally)
> 
> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
> Cc: Chris Wilson <chris@chris-wilson.co.uk>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
> ---
>   lib/igt_core.c | 20 ++++++++++----------
>   1 file changed, 10 insertions(+), 10 deletions(-)
> 
> diff --git a/lib/igt_core.c b/lib/igt_core.c
> index b38498e9d13b..5f1d1d34dbc6 100644
> --- a/lib/igt_core.c
> +++ b/lib/igt_core.c
> @@ -1231,6 +1231,16 @@ static bool run_under_gdb(void)
>   		strncmp(basename(buf), "gdb", 3) == 0);
>   }
>   
> +static void __write_stderr(const char *str, size_t len)
> +{
> +	igt_ignore_warn(write(STDERR_FILENO, str, len));
> +}
> +
> +static void write_stderr(const char *str)
> +{
> +	__write_stderr(str, strlen(str));
> +}
> +
>   #ifdef HAVE_LIBUNWIND
>   #define UNW_LOCAL_ONLY
>   #include <libunwind.h>
> @@ -1407,16 +1417,6 @@ xprintf(const char *fmt, ...)
>   	va_end(ap);
>   }
>   
> -static void __write_stderr(const char *str, size_t len)
> -{
> -	igt_ignore_warn(write(STDERR_FILENO, str, len));
> -}
> -
> -static void write_stderr(const char *str)
> -{
> -	__write_stderr(str, strlen(str));
> -}
> -
>   static void print_backtrace_sig_safe(void)
>   {
>   	unw_cursor_t cursor;
> 

Arek spotted this and fixed on Friday already, so you can drop it from 
your series.

Regards,

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

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

* ✗ Fi.CI.IGT: warning for series starting with [1/4] lib: avoid < in gtkdoc comments (rev3)
  2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
                   ` (6 preceding siblings ...)
  2017-11-27  8:17 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev3) Patchwork
@ 2017-11-27  9:04 ` Patchwork
  7 siblings, 0 replies; 12+ messages in thread
From: Patchwork @ 2017-11-27  9:04 UTC (permalink / raw)
  To: Daniel Vetter; +Cc: intel-gfx

== Series Details ==

Series: series starting with [1/4] lib: avoid < in gtkdoc comments (rev3)
URL   : https://patchwork.freedesktop.org/series/34413/
State : warning

== Summary ==

Test drv_module_reload:
        Subgroup basic-no-display:
                dmesg-warn -> PASS       (shard-snb) fdo#102707
Test kms_frontbuffer_tracking:
        Subgroup fbc-1p-offscren-pri-shrfb-draw-render:
                fail       -> PASS       (shard-snb) fdo#101623 +1
Test drm_read:
        Subgroup short-buffer-nonblock:
                pass       -> SKIP       (shard-snb)
Test perf:
        Subgroup blocking:
                fail       -> PASS       (shard-hsw) fdo#102252
Test drv_selftest:
        Subgroup mock_sanitycheck:
                dmesg-warn -> PASS       (shard-snb) fdo#103717
Test kms_flip:
        Subgroup flip-vs-expired-vblank-interruptible:
                fail       -> PASS       (shard-hsw) fdo#102887

fdo#102707 https://bugs.freedesktop.org/show_bug.cgi?id=102707
fdo#101623 https://bugs.freedesktop.org/show_bug.cgi?id=101623
fdo#102252 https://bugs.freedesktop.org/show_bug.cgi?id=102252
fdo#103717 https://bugs.freedesktop.org/show_bug.cgi?id=103717
fdo#102887 https://bugs.freedesktop.org/show_bug.cgi?id=102887

shard-hsw        total:2662 pass:1535 dwarn:1   dfail:0   fail:10  skip:1116 time:9515s
shard-snb        total:2662 pass:1306 dwarn:1   dfail:0   fail:12  skip:1343 time:8067s
Blacklisted hosts:
shard-apl        total:2662 pass:1685 dwarn:5   dfail:0   fail:22  skip:949 time:13632s
shard-kbl        total:2662 pass:1796 dwarn:8   dfail:0   fail:23  skip:835 time:10929s

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/IGTPW_553/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

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

end of thread, other threads:[~2017-11-27  9:04 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-26 19:42 [PATCH i-g-t 1/4] lib: avoid < in gtkdoc comments Daniel Vetter
2017-11-26 19:42 ` [PATCH i-g-t 2/4] docs: remove version information Daniel Vetter
2017-11-26 19:42 ` [PATCH i-g-t 3/4] lib: move write_stderr out of the #ifdef Daniel Vetter
2017-11-27  8:33   ` Tvrtko Ursulin
2017-11-26 19:42 ` [PATCH i-g-t 4/4] meson: gtkdoc support Daniel Vetter
2017-11-26 19:57   ` [PATCH i-g-t] " Daniel Vetter
2017-11-27  7:59   ` Daniel Vetter
2017-11-26 20:01 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments Patchwork
2017-11-26 20:42 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev2) Patchwork
2017-11-26 21:49 ` ✗ Fi.CI.IGT: warning " Patchwork
2017-11-27  8:17 ` ✓ Fi.CI.BAT: success for series starting with [1/4] lib: avoid < in gtkdoc comments (rev3) Patchwork
2017-11-27  9:04 ` ✗ Fi.CI.IGT: warning " Patchwork

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.