All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Corbet <corbet@lwn.net>
To: Markus Heiser <markus.heiser@darmarit.de>
Cc: Mauro Carvalho Chehab <mchehab@s-opensource.com>,
	Jani Nikula <jani.nikula@intel.com>,
	Linux Doc Mailing List <linux-doc@vger.kernel.org>,
	Mauro Carvalho Chehab <mchehab@infradead.org>,
	"linux-kernel@vger.kernel.org org List" 
	<linux-kernel@vger.kernel.org>,
	David Woodhouse <dwmw2@infradead.org>,
	Brian Norris <computersforpeace@gmail.com>,
	Boris Brezillon <boris.brezillon@free-electrons.com>,
	Marek Vasut <marek.vasut@gmail.com>,
	Richard Weinberger <richard@nod.at>,
	Cyrille Pitchen <cyrille.pitchen@atmel.com>,
	linux-mtd@lists.infradead.org
Subject: Re: [PATCH v2 00/53] Get rid of Docbook
Date: Fri, 23 Jun 2017 14:26:54 -0600	[thread overview]
Message-ID: <20170623142654.128ac5e3@lwn.net> (raw)
In-Reply-To: <C33A12EC-8748-4BB9-A7A2-023B1901AB4B@darmarit.de>

On Fri, 16 Jun 2017 16:03:23 +0200
Markus Heiser <markus.heiser@darmarit.de> wrote:

> I guess there are little remains lying around ;) what I have found:

I just committed the following to clean up that stuff, thanks.

jon

>From 52b3f239bb692d9b3a68461798fb15c011e4108e Mon Sep 17 00:00:00 2001
From: Jonathan Corbet <corbet@lwn.net>
Date: Fri, 23 Jun 2017 14:17:38 -0600
Subject: [PATCH] Docs: clean up some DocBook loose ends

There were a few bits and pieces left over from the now-disused DocBook
toolchain; git rid of them.

Reported-by: Markus Heiser <markus.heiser@darmarit.de>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
---
 Documentation/dontdiff                    |   1 -
 Documentation/sphinx/convert_template.sed |  18 -
 Documentation/sphinx/post_convert.sed     |  23 -
 MAINTAINERS                               |   3 +-
 Makefile                                  |   1 -
 scripts/.gitignore                        |   1 -
 scripts/Makefile                          |   7 +-
 scripts/docproc.c                         | 681 ------------------------------
 scripts/kernel-doc-xml-ref                | 198 ---------
 9 files changed, 3 insertions(+), 930 deletions(-)
 delete mode 100644 Documentation/sphinx/convert_template.sed
 delete mode 100644 Documentation/sphinx/post_convert.sed
 delete mode 100644 scripts/docproc.c
 delete mode 100755 scripts/kernel-doc-xml-ref

diff --git a/Documentation/dontdiff b/Documentation/dontdiff
index 77b92221f951..f64a63b233c3 100644
--- a/Documentation/dontdiff
+++ b/Documentation/dontdiff
@@ -118,7 +118,6 @@ defkeymap.c
 devlist.h*
 devicetable-offsets.h
 dnotify_test
-docproc
 dslm
 dtc
 elf2ecoff
diff --git a/Documentation/sphinx/convert_template.sed b/Documentation/sphinx/convert_template.sed
deleted file mode 100644
index c1503fcca4ec..000000000000
--- a/Documentation/sphinx/convert_template.sed
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Pandoc doesn't grok <function> or <structname>, so convert them
-# ahead of time.
-#
-# Use the following escapes to pass through pandoc:
-#	$bq = "`"
-#	$lt = "<"
-#	$gt = ">"
-#
-s%<function>\([^<(]\+\)()</function>%:c:func:$bq\1()$bq%g
-s%<function>\([^<(]\+\)</function>%:c:func:$bq\1()$bq%g
-s%<structname>struct *\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-s%struct <structname>\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-s%<structname>\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-#
-# Wrap docproc directives in para and code blocks.
-#
-s%^\(!.*\)$%<para><code>DOCPROC: \1</code></para>%
diff --git a/Documentation/sphinx/post_convert.sed b/Documentation/sphinx/post_convert.sed
deleted file mode 100644
index 392770bac53b..000000000000
--- a/Documentation/sphinx/post_convert.sed
+++ /dev/null
@@ -1,23 +0,0 @@
-#
-# Unescape.
-#
-s/$bq/`/g
-s/$lt/</g
-s/$gt/>/g
-#
-# pandoc thinks that both "_" needs to be escaped.  Remove the extra
-# backslashes.
-#
-s/\\_/_/g
-#
-# Unwrap docproc directives.
-#
-s/^``DOCPROC: !E\(.*\)``$/.. kernel-doc:: \1\n   :export:/
-s/^``DOCPROC: !I\(.*\)``$/.. kernel-doc:: \1\n   :internal:/
-s/^``DOCPROC: !F\([^ ]*\) \(.*\)``$/.. kernel-doc:: \1\n   :functions: \2/
-s/^``DOCPROC: !P\([^ ]*\) \(.*\)``$/.. kernel-doc:: \1\n   :doc: \2/
-s/^``DOCPROC: \(!.*\)``$/.. WARNING: DOCPROC directive not supported: \1/
-#
-# Trim trailing whitespace.
-#
-s/[[:space:]]*$//
diff --git a/MAINTAINERS b/MAINTAINERS
index 5df61e9757dc..12110616b2d2 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -4135,8 +4135,7 @@ M:	Jonathan Corbet <corbet@lwn.net>
 L:	linux-doc@vger.kernel.org
 S:	Maintained
 F:	Documentation/
-F:	scripts/docproc.c
-F:	scripts/kernel-doc*
+F:	scripts/kernel-doc
 X:	Documentation/ABI/
 X:	Documentation/devicetree/
 X:	Documentation/acpi
diff --git a/Makefile b/Makefile
index 855a48c41d61..dd1eb8d6c232 100644
--- a/Makefile
+++ b/Makefile
@@ -1467,7 +1467,6 @@ $(help-board-dirs): help-%:
 DOC_TARGETS := xmldocs sgmldocs psdocs latexdocs pdfdocs htmldocs mandocs installmandocs epubdocs cleandocs linkcheckdocs
 PHONY += $(DOC_TARGETS)
 $(DOC_TARGETS): scripts_basic FORCE
-	$(Q)$(MAKE) $(build)=scripts build_docproc
 	$(Q)$(MAKE) $(build)=Documentation $@
 
 else # KBUILD_EXTMOD
diff --git a/scripts/.gitignore b/scripts/.gitignore
index e063daa3ec4a..0442c06eefcb 100644
--- a/scripts/.gitignore
+++ b/scripts/.gitignore
@@ -7,7 +7,6 @@ pnmtologo
 unifdef
 ihex2fw
 recordmcount
-docproc
 check-lc_ctype
 sortextable
 asn1_compiler
diff --git a/scripts/Makefile b/scripts/Makefile
index 55550e4141c4..c06f4997d700 100644
--- a/scripts/Makefile
+++ b/scripts/Makefile
@@ -6,7 +6,6 @@
 # pnmttologo:    Convert pnm files to logo files
 # conmakehash:   Create chartable
 # conmakehash:	 Create arrays for initializing the kernel console tables
-# docproc:       Used in Documentation/
 
 HOST_EXTRACFLAGS += -I$(srctree)/tools/include
 
@@ -28,14 +27,12 @@ HOSTLOADLIBES_extract-cert = -lcrypto
 always		:= $(hostprogs-y) $(hostprogs-m)
 
 # The following hostprogs-y programs are only build on demand
-hostprogs-y += unifdef docproc
+hostprogs-y += unifdef
 
 # These targets are used internally to avoid "is up to date" messages
-PHONY += build_unifdef build_docproc
+PHONY += build_unifdef
 build_unifdef: $(obj)/unifdef
 	@:
-build_docproc: $(obj)/docproc
-	@:
 
 subdir-$(CONFIG_MODVERSIONS) += genksyms
 subdir-y                     += mod
diff --git a/scripts/docproc.c b/scripts/docproc.c
deleted file mode 100644
index 0a12593b9041..000000000000
--- a/scripts/docproc.c
+++ /dev/null
@@ -1,681 +0,0 @@
-/*
- *	docproc is a simple preprocessor for the template files
- *      used as placeholders for the kernel internal documentation.
- *	docproc is used for documentation-frontend and
- *      dependency-generator.
- *	The two usages have in common that they require
- *	some knowledge of the .tmpl syntax, therefore they
- *	are kept together.
- *
- *	documentation-frontend
- *		Scans the template file and call kernel-doc for
- *		all occurrences of ![EIF]file
- *		Beforehand each referenced file is scanned for
- *		any symbols that are exported via these macros:
- *			EXPORT_SYMBOL(), EXPORT_SYMBOL_GPL(), &
- *			EXPORT_SYMBOL_GPL_FUTURE()
- *		This is used to create proper -function and
- *		-nofunction arguments in calls to kernel-doc.
- *		Usage: docproc doc file.tmpl
- *
- *	dependency-generator:
- *		Scans the template file and list all files
- *		referenced in a format recognized by make.
- *		Usage:	docproc depend file.tmpl
- *		Writes dependency information to stdout
- *		in the following format:
- *		file.tmpl src.c	src2.c
- *		The filenames are obtained from the following constructs:
- *		!Efilename
- *		!Ifilename
- *		!Dfilename
- *		!Ffilename
- *		!Pfilename
- *
- */
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <unistd.h>
-#include <limits.h>
-#include <errno.h>
-#include <getopt.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-#include <time.h>
-
-/* exitstatus is used to keep track of any failing calls to kernel-doc,
- * but execution continues. */
-int exitstatus = 0;
-
-typedef void DFL(char *);
-DFL *defaultline;
-
-typedef void FILEONLY(char * file);
-FILEONLY *internalfunctions;
-FILEONLY *externalfunctions;
-FILEONLY *symbolsonly;
-FILEONLY *findall;
-
-typedef void FILELINE(char * file, char * line);
-FILELINE * singlefunctions;
-FILELINE * entity_system;
-FILELINE * docsection;
-
-#define MAXLINESZ     2048
-#define MAXFILES      250
-#define KERNELDOCPATH "scripts/"
-#define KERNELDOC     "kernel-doc"
-#define DOCBOOK       "-docbook"
-#define RST           "-rst"
-#define LIST          "-list"
-#define FUNCTION      "-function"
-#define NOFUNCTION    "-nofunction"
-#define NODOCSECTIONS "-no-doc-sections"
-#define SHOWNOTFOUND  "-show-not-found"
-
-enum file_format {
-	FORMAT_AUTO,
-	FORMAT_DOCBOOK,
-	FORMAT_RST,
-};
-
-static enum file_format file_format = FORMAT_AUTO;
-
-#define KERNELDOC_FORMAT	(file_format == FORMAT_RST ? RST : DOCBOOK)
-
-static char *srctree, *kernsrctree;
-
-static char **all_list = NULL;
-static int all_list_len = 0;
-
-static void consume_symbol(const char *sym)
-{
-	int i;
-
-	for (i = 0; i < all_list_len; i++) {
-		if (!all_list[i])
-			continue;
-		if (strcmp(sym, all_list[i]))
-			continue;
-		all_list[i] = NULL;
-		break;
-	}
-}
-
-static void usage (void)
-{
-	fprintf(stderr, "Usage: docproc [{--docbook|--rst}] {doc|depend} file\n");
-	fprintf(stderr, "Input is read from file.tmpl. Output is sent to stdout\n");
-	fprintf(stderr, "doc: frontend when generating kernel documentation\n");
-	fprintf(stderr, "depend: generate list of files referenced within file\n");
-	fprintf(stderr, "Environment variable SRCTREE: absolute path to sources.\n");
-	fprintf(stderr, "                     KBUILD_SRC: absolute path to kernel source tree.\n");
-}
-
-/*
- * Execute kernel-doc with parameters given in svec
- */
-static void exec_kernel_doc(char **svec)
-{
-	pid_t pid;
-	int ret;
-	char real_filename[PATH_MAX + 1];
-	/* Make sure output generated so far are flushed */
-	fflush(stdout);
-	switch (pid=fork()) {
-		case -1:
-			perror("fork");
-			exit(1);
-		case  0:
-			memset(real_filename, 0, sizeof(real_filename));
-			strncat(real_filename, kernsrctree, PATH_MAX);
-			strncat(real_filename, "/" KERNELDOCPATH KERNELDOC,
-					PATH_MAX - strlen(real_filename));
-			execvp(real_filename, svec);
-			fprintf(stderr, "exec ");
-			perror(real_filename);
-			exit(1);
-		default:
-			waitpid(pid, &ret ,0);
-	}
-	if (WIFEXITED(ret))
-		exitstatus |= WEXITSTATUS(ret);
-	else
-		exitstatus = 0xff;
-}
-
-/* Types used to create list of all exported symbols in a number of files */
-struct symbols
-{
-	char *name;
-};
-
-struct symfile
-{
-	char *filename;
-	struct symbols *symbollist;
-	int symbolcnt;
-};
-
-struct symfile symfilelist[MAXFILES];
-int symfilecnt = 0;
-
-static void add_new_symbol(struct symfile *sym, char * symname)
-{
-	sym->symbollist =
-	  realloc(sym->symbollist, (sym->symbolcnt + 1) * sizeof(char *));
-	sym->symbollist[sym->symbolcnt++].name = strdup(symname);
-}
-
-/* Add a filename to the list */
-static struct symfile * add_new_file(char * filename)
-{
-	symfilelist[symfilecnt++].filename = strdup(filename);
-	return &symfilelist[symfilecnt - 1];
-}
-
-/* Check if file already are present in the list */
-static struct symfile * filename_exist(char * filename)
-{
-	int i;
-	for (i=0; i < symfilecnt; i++)
-		if (strcmp(symfilelist[i].filename, filename) == 0)
-			return &symfilelist[i];
-	return NULL;
-}
-
-/*
- * List all files referenced within the template file.
- * Files are separated by tabs.
- */
-static void adddep(char * file)		   { printf("\t%s", file); }
-static void adddep2(char * file, char * line)     { line = line; adddep(file); }
-static void noaction(char * line)		   { line = line; }
-static void noaction2(char * file, char * line)   { file = file; line = line; }
-
-/* Echo the line without further action */
-static void printline(char * line)               { printf("%s", line); }
-
-/*
- * Find all symbols in filename that are exported with EXPORT_SYMBOL &
- * EXPORT_SYMBOL_GPL (& EXPORT_SYMBOL_GPL_FUTURE implicitly).
- * All symbols located are stored in symfilelist.
- */
-static void find_export_symbols(char * filename)
-{
-	FILE * fp;
-	struct symfile *sym;
-	char line[MAXLINESZ];
-	if (filename_exist(filename) == NULL) {
-		char real_filename[PATH_MAX + 1];
-		memset(real_filename, 0, sizeof(real_filename));
-		strncat(real_filename, srctree, PATH_MAX);
-		strncat(real_filename, "/", PATH_MAX - strlen(real_filename));
-		strncat(real_filename, filename,
-				PATH_MAX - strlen(real_filename));
-		sym = add_new_file(filename);
-		fp = fopen(real_filename, "r");
-		if (fp == NULL)	{
-			fprintf(stderr, "docproc: ");
-			perror(real_filename);
-			exit(1);
-		}
-		while (fgets(line, MAXLINESZ, fp)) {
-			char *p;
-			char *e;
-			if (((p = strstr(line, "EXPORT_SYMBOL_GPL")) != NULL) ||
-			    ((p = strstr(line, "EXPORT_SYMBOL")) != NULL)) {
-				/* Skip EXPORT_SYMBOL{_GPL} */
-				while (isalnum(*p) || *p == '_')
-					p++;
-				/* Remove parentheses & additional whitespace */
-				while (isspace(*p))
-					p++;
-				if (*p != '(')
-					continue; /* Syntax error? */
-				else
-					p++;
-				while (isspace(*p))
-					p++;
-				e = p;
-				while (isalnum(*e) || *e == '_')
-					e++;
-				*e = '\0';
-				add_new_symbol(sym, p);
-			}
-		}
-		fclose(fp);
-	}
-}
-
-/*
- * Document all external or internal functions in a file.
- * Call kernel-doc with following parameters:
- * kernel-doc [-docbook|-rst] -nofunction function_name1 filename
- * Function names are obtained from all the src files
- * by find_export_symbols.
- * intfunc uses -nofunction
- * extfunc uses -function
- */
-static void docfunctions(char * filename, char * type)
-{
-	int i,j;
-	int symcnt = 0;
-	int idx = 0;
-	char **vec;
-
-	for (i=0; i <= symfilecnt; i++)
-		symcnt += symfilelist[i].symbolcnt;
-	vec = malloc((2 + 2 * symcnt + 3) * sizeof(char *));
-	if (vec == NULL) {
-		perror("docproc: ");
-		exit(1);
-	}
-	vec[idx++] = KERNELDOC;
-	vec[idx++] = KERNELDOC_FORMAT;
-	vec[idx++] = NODOCSECTIONS;
-	for (i=0; i < symfilecnt; i++) {
-		struct symfile * sym = &symfilelist[i];
-		for (j=0; j < sym->symbolcnt; j++) {
-			vec[idx++]     = type;
-			consume_symbol(sym->symbollist[j].name);
-			vec[idx++] = sym->symbollist[j].name;
-		}
-	}
-	vec[idx++]     = filename;
-	vec[idx] = NULL;
-	if (file_format == FORMAT_RST)
-		printf(".. %s\n", filename);
-	else
-		printf("<!-- %s -->\n", filename);
-	exec_kernel_doc(vec);
-	fflush(stdout);
-	free(vec);
-}
-static void intfunc(char * filename) {	docfunctions(filename, NOFUNCTION); }
-static void extfunc(char * filename) { docfunctions(filename, FUNCTION);   }
-
-/*
- * Document specific function(s) in a file.
- * Call kernel-doc with the following parameters:
- * kernel-doc -docbook -function function1 [-function function2]
- */
-static void singfunc(char * filename, char * line)
-{
-	char *vec[200]; /* Enough for specific functions */
-	int i, idx = 0;
-	int startofsym = 1;
-	vec[idx++] = KERNELDOC;
-	vec[idx++] = KERNELDOC_FORMAT;
-	vec[idx++] = SHOWNOTFOUND;
-
-	/* Split line up in individual parameters preceded by FUNCTION */
-	for (i=0; line[i]; i++) {
-		if (isspace(line[i])) {
-			line[i] = '\0';
-			startofsym = 1;
-			continue;
-		}
-		if (startofsym) {
-			startofsym = 0;
-			vec[idx++] = FUNCTION;
-			vec[idx++] = &line[i];
-		}
-	}
-	for (i = 0; i < idx; i++) {
-		if (strcmp(vec[i], FUNCTION))
-			continue;
-		consume_symbol(vec[i + 1]);
-	}
-	vec[idx++] = filename;
-	vec[idx] = NULL;
-	exec_kernel_doc(vec);
-}
-
-/*
- * Insert specific documentation section from a file.
- * Call kernel-doc with the following parameters:
- * kernel-doc -docbook -function "doc section" filename
- */
-static void docsect(char *filename, char *line)
-{
-	/* kerneldoc -docbook -show-not-found -function "section" file NULL */
-	char *vec[7];
-	char *s;
-
-	for (s = line; *s; s++)
-		if (*s == '\n')
-			*s = '\0';
-
-	if (asprintf(&s, "DOC: %s", line) < 0) {
-		perror("asprintf");
-		exit(1);
-	}
-	consume_symbol(s);
-	free(s);
-
-	vec[0] = KERNELDOC;
-	vec[1] = KERNELDOC_FORMAT;
-	vec[2] = SHOWNOTFOUND;
-	vec[3] = FUNCTION;
-	vec[4] = line;
-	vec[5] = filename;
-	vec[6] = NULL;
-	exec_kernel_doc(vec);
-}
-
-static void find_all_symbols(char *filename)
-{
-	char *vec[4]; /* kerneldoc -list file NULL */
-	pid_t pid;
-	int ret, i, count, start;
-	char real_filename[PATH_MAX + 1];
-	int pipefd[2];
-	char *data, *str;
-	size_t data_len = 0;
-
-	vec[0] = KERNELDOC;
-	vec[1] = LIST;
-	vec[2] = filename;
-	vec[3] = NULL;
-
-	if (pipe(pipefd)) {
-		perror("pipe");
-		exit(1);
-	}
-
-	switch (pid=fork()) {
-		case -1:
-			perror("fork");
-			exit(1);
-		case  0:
-			close(pipefd[0]);
-			dup2(pipefd[1], 1);
-			memset(real_filename, 0, sizeof(real_filename));
-			strncat(real_filename, kernsrctree, PATH_MAX);
-			strncat(real_filename, "/" KERNELDOCPATH KERNELDOC,
-					PATH_MAX - strlen(real_filename));
-			execvp(real_filename, vec);
-			fprintf(stderr, "exec ");
-			perror(real_filename);
-			exit(1);
-		default:
-			close(pipefd[1]);
-			data = malloc(4096);
-			do {
-				while ((ret = read(pipefd[0],
-						   data + data_len,
-						   4096)) > 0) {
-					data_len += ret;
-					data = realloc(data, data_len + 4096);
-				}
-			} while (ret == -EAGAIN);
-			if (ret != 0) {
-				perror("read");
-				exit(1);
-			}
-			waitpid(pid, &ret ,0);
-	}
-	if (WIFEXITED(ret))
-		exitstatus |= WEXITSTATUS(ret);
-	else
-		exitstatus = 0xff;
-
-	count = 0;
-	/* poor man's strtok, but with counting */
-	for (i = 0; i < data_len; i++) {
-		if (data[i] == '\n') {
-			count++;
-			data[i] = '\0';
-		}
-	}
-	start = all_list_len;
-	all_list_len += count;
-	all_list = realloc(all_list, sizeof(char *) * all_list_len);
-	str = data;
-	for (i = 0; i < data_len && start != all_list_len; i++) {
-		if (data[i] == '\0') {
-			all_list[start] = str;
-			str = data + i + 1;
-			start++;
-		}
-	}
-}
-
-/*
- * Terminate s at first space, if any. If there was a space, return pointer to
- * the character after that. Otherwise, return pointer to the terminating NUL.
- */
-static char *chomp(char *s)
-{
-	while (*s && !isspace(*s))
-		s++;
-
-	if (*s)
-		*s++ = '\0';
-
-	return s;
-}
-
-/* Return pointer to directive content, or NULL if not a directive. */
-static char *is_directive(char *line)
-{
-	if (file_format == FORMAT_DOCBOOK && line[0] == '!')
-		return line + 1;
-	else if (file_format == FORMAT_RST && !strncmp(line, ".. !", 4))
-		return line + 4;
-
-	return NULL;
-}
-
-/*
- * Parse file, calling action specific functions for:
- * 1) Lines containing !E
- * 2) Lines containing !I
- * 3) Lines containing !D
- * 4) Lines containing !F
- * 5) Lines containing !P
- * 6) Lines containing !C
- * 7) Default lines - lines not matching the above
- */
-static void parse_file(FILE *infile)
-{
-	char line[MAXLINESZ];
-	char *p, *s;
-	while (fgets(line, MAXLINESZ, infile)) {
-		p = is_directive(line);
-		if (!p) {
-			defaultline(line);
-			continue;
-		}
-
-		switch (*p++) {
-		case 'E':
-			chomp(p);
-			externalfunctions(p);
-			break;
-		case 'I':
-			chomp(p);
-			internalfunctions(p);
-			break;
-		case 'D':
-			chomp(p);
-			symbolsonly(p);
-			break;
-		case 'F':
-			/* filename */
-			s = chomp(p);
-			/* function names */
-			while (isspace(*s))
-				s++;
-			singlefunctions(p, s);
-			break;
-		case 'P':
-			/* filename */
-			s = chomp(p);
-			/* DOC: section name */
-			while (isspace(*s))
-				s++;
-			docsection(p, s);
-			break;
-		case 'C':
-			chomp(p);
-			if (findall)
-				findall(p);
-			break;
-		default:
-			defaultline(line);
-		}
-	}
-	fflush(stdout);
-}
-
-/*
- * Is this a RestructuredText template?  Answer the question by seeing if its
- * name ends in ".rst".
- */
-static int is_rst(const char *file)
-{
-	char *dot = strrchr(file, '.');
-
-	return dot && !strcmp(dot + 1, "rst");
-}
-
-enum opts {
-	OPT_DOCBOOK,
-	OPT_RST,
-	OPT_HELP,
-};
-
-int main(int argc, char *argv[])
-{
-	const char *subcommand, *filename;
-	FILE * infile;
-	int i;
-
-	srctree = getenv("SRCTREE");
-	if (!srctree)
-		srctree = getcwd(NULL, 0);
-	kernsrctree = getenv("KBUILD_SRC");
-	if (!kernsrctree || !*kernsrctree)
-		kernsrctree = srctree;
-
-	for (;;) {
-		int c;
-		struct option opts[] = {
-			{ "docbook",	no_argument, NULL, OPT_DOCBOOK },
-			{ "rst",	no_argument, NULL, OPT_RST },
-			{ "help",	no_argument, NULL, OPT_HELP },
-			{}
-		};
-
-		c = getopt_long_only(argc, argv, "", opts, NULL);
-		if (c == -1)
-			break;
-
-		switch (c) {
-		case OPT_DOCBOOK:
-			file_format = FORMAT_DOCBOOK;
-			break;
-		case OPT_RST:
-			file_format = FORMAT_RST;
-			break;
-		case OPT_HELP:
-			usage();
-			return 0;
-		default:
-		case '?':
-			usage();
-			return 1;
-		}
-	}
-
-	argc -= optind;
-	argv += optind;
-
-	if (argc != 2) {
-		usage();
-		exit(1);
-	}
-
-	subcommand = argv[0];
-	filename = argv[1];
-
-	if (file_format == FORMAT_AUTO)
-		file_format = is_rst(filename) ? FORMAT_RST : FORMAT_DOCBOOK;
-
-	/* Open file, exit on error */
-	infile = fopen(filename, "r");
-	if (infile == NULL) {
-		fprintf(stderr, "docproc: ");
-		perror(filename);
-		exit(2);
-	}
-
-	if (strcmp("doc", subcommand) == 0) {
-		if (file_format == FORMAT_RST) {
-			time_t t = time(NULL);
-			printf(".. generated from %s by docproc %s\n",
-			       filename, ctime(&t));
-		}
-
-		/* Need to do this in two passes.
-		 * First pass is used to collect all symbols exported
-		 * in the various files;
-		 * Second pass generate the documentation.
-		 * This is required because some functions are declared
-		 * and exported in different files :-((
-		 */
-		/* Collect symbols */
-		defaultline       = noaction;
-		internalfunctions = find_export_symbols;
-		externalfunctions = find_export_symbols;
-		symbolsonly       = find_export_symbols;
-		singlefunctions   = noaction2;
-		docsection        = noaction2;
-		findall           = find_all_symbols;
-		parse_file(infile);
-
-		/* Rewind to start from beginning of file again */
-		fseek(infile, 0, SEEK_SET);
-		defaultline       = printline;
-		internalfunctions = intfunc;
-		externalfunctions = extfunc;
-		symbolsonly       = printline;
-		singlefunctions   = singfunc;
-		docsection        = docsect;
-		findall           = NULL;
-
-		parse_file(infile);
-
-		for (i = 0; i < all_list_len; i++) {
-			if (!all_list[i])
-				continue;
-			fprintf(stderr, "Warning: didn't use docs for %s\n",
-				all_list[i]);
-		}
-	} else if (strcmp("depend", subcommand) == 0) {
-		/* Create first part of dependency chain
-		 * file.tmpl */
-		printf("%s\t", filename);
-		defaultline       = noaction;
-		internalfunctions = adddep;
-		externalfunctions = adddep;
-		symbolsonly       = adddep;
-		singlefunctions   = adddep2;
-		docsection        = adddep2;
-		findall           = adddep;
-		parse_file(infile);
-		printf("\n");
-	} else {
-		fprintf(stderr, "Unknown option: %s\n", subcommand);
-		exit(1);
-	}
-	fclose(infile);
-	fflush(stdout);
-	return exitstatus;
-}
diff --git a/scripts/kernel-doc-xml-ref b/scripts/kernel-doc-xml-ref
deleted file mode 100755
index 104a5a5ba2c8..000000000000
--- a/scripts/kernel-doc-xml-ref
+++ /dev/null
@@ -1,198 +0,0 @@
-#!/usr/bin/perl -w
-
-use strict;
-
-## Copyright (C) 2015  Intel Corporation                         ##
-#                                                                ##
-## This software falls under the GNU General Public License.     ##
-## Please read the COPYING file for more information             ##
-#
-#
-# This software reads a XML file and a list of valid interal
-# references to replace Docbook tags with links.
-#
-# The list of "valid internal references" must be one-per-line in the following format:
-#      API-struct-foo
-#      API-enum-bar
-#      API-my-function
-#
-# The software walks over the XML file looking for xml tags representing possible references
-# to the Document. Each reference will be cross checked against the "Valid Internal Reference" list. If
-# the referece is found it replaces its content by a <link> tag.
-#
-# usage:
-# kernel-doc-xml-ref -db filename
-#		     xml filename > outputfile
-
-# read arguments
-if ($#ARGV != 2) {
-	usage();
-}
-
-#Holds the database filename
-my $databasefile;
-my @database;
-
-#holds the inputfile
-my $inputfile;
-my $errors = 0;
-
-my %highlights = (
-	"<function>(.*?)</function>",
-	    "\"<function>\" . convert_function(\$1, \$line) . \"</function>\"",
-	"<structname>(.*?)</structname>",
-	    "\"<structname>\" . convert_struct(\$1) . \"</structname>\"",
-	"<funcdef>(.*?)<function>(.*?)</function></funcdef>",
-	    "\"<funcdef>\" . convert_param(\$1) . \"<function>\$2</function></funcdef>\"",
-	"<paramdef>(.*?)<parameter>(.*?)</parameter></paramdef>",
-	    "\"<paramdef>\" . convert_param(\$1) . \"<parameter>\$2</parameter></paramdef>\"");
-
-while($ARGV[0] =~ m/^-(.*)/) {
-	my $cmd = shift @ARGV;
-	if ($cmd eq "-db") {
-		$databasefile = shift @ARGV
-	} else {
-		usage();
-	}
-}
-$inputfile = shift @ARGV;
-
-sub open_database {
-	open (my $handle, '<', $databasefile) or die "Cannot open $databasefile";
-	chomp(my @lines = <$handle>);
-	close $handle;
-
-	@database = @lines;
-}
-
-sub process_file {
-	open_database();
-
-	my $dohighlight;
-	foreach my $pattern (keys %highlights) {
-		$dohighlight .=  "\$line =~ s:$pattern:$highlights{$pattern}:eg;\n";
-	}
-
-	open(FILE, $inputfile) or die("Could not open $inputfile") or die ("Cannot open $inputfile");
-	foreach my $line (<FILE>)  {
-		eval $dohighlight;
-		print $line;
-	}
-}
-
-sub trim($_)
-{
-	my $str = $_[0];
-	$str =~ s/^\s+|\s+$//g;
-	return $str
-}
-
-sub has_key_defined($_)
-{
-	if ( grep( /^$_[0]$/, @database)) {
-		return 1;
-	}
-	return 0;
-}
-
-# Gets a <function> content and add it a hyperlink if possible.
-sub convert_function($_)
-{
-	my $arg = $_[0];
-	my $key = $_[0];
-
-	my $line = $_[1];
-
-	$key = trim($key);
-
-	$key =~ s/[^A-Za-z0-9]/-/g;
-	$key = "API-" . $key;
-
-	# We shouldn't add links to <funcdef> prototype
-	if (!has_key_defined($key) || $line =~ m/\s+<funcdef/i) {
-		return $arg;
-	}
-
-	my $head = $arg;
-	my $tail = "";
-	if ($arg =~ /(.*?)( ?)$/) {
-		$head = $1;
-		$tail = $2;
-	}
-	return "<link linkend=\"$key\">$head</link>$tail";
-}
-
-# Converting a struct text to link
-sub convert_struct($_)
-{
-	my $arg = $_[0];
-	my $key = $_[0];
-	$key =~ s/(struct )?(\w)/$2/g;
-	$key =~ s/[^A-Za-z0-9]/-/g;
-	$key = "API-struct-" . $key;
-
-	if (!has_key_defined($key)) {
-		return $arg;
-	}
-
-	my ($head, $tail) = split_pointer($arg);
-	return "<link linkend=\"$key\">$head</link>$tail";
-}
-
-# Identify "object *" elements
-sub split_pointer($_)
-{
-	my $arg = $_[0];
-	if ($arg =~ /(.*?)( ?\* ?)/) {
-		return ($1, $2);
-	}
-	return ($arg, "");
-}
-
-sub convert_param($_)
-{
-	my $type = $_[0];
-	my $keyname = convert_key_name($type);
-
-	if (!has_key_defined($keyname)) {
-		return $type;
-	}
-
-	my ($head, $tail) = split_pointer($type);
-	return "<link linkend=\"$keyname\">$head</link>$tail";
-
-}
-
-# DocBook links are in the API-<TYPE>-<STRUCT-NAME> format
-# This method gets an element and returns a valid DocBook reference for it.
-sub convert_key_name($_)
-{
-	#Pattern $2 is optional and might be uninitialized
-	no warnings 'uninitialized';
-
-	my $str = $_[0];
-	$str =~ s/(const|static)? ?(struct)? ?([a-zA-Z0-9_]+) ?(\*|&)?/$2 $3/g ;
-
-	# trim
-	$str =~ s/^\s+|\s+$//g;
-
-	# spaces and _ to -
-	$str =~ s/[^A-Za-z0-9]/-/g;
-
-	return "API-" . $str;
-}
-
-sub usage {
-	print "Usage: $0 -db database filename\n";
-	print "         xml source file(s) > outputfile\n";
-	exit 1;
-}
-
-# starting point
-process_file();
-
-if ($errors) {
-	print STDERR "$errors errors\n";
-}
-
-exit($errors);
-- 
2.13.1

WARNING: multiple messages have this Message-ID (diff)
From: Jonathan Corbet <corbet@lwn.net>
To: Markus Heiser <markus.heiser@darmarit.de>
Cc: Mauro Carvalho Chehab <mchehab@s-opensource.com>,
	Jani Nikula <jani.nikula@intel.com>,
	Linux Doc Mailing List <linux-doc@vger.kernel.org>,
	Mauro Carvalho Chehab <mchehab@infradead.org>,
	"linux-kernel@vger.kernel.org org List"
	<linux-kernel@vger.kernel.org>,
	David Woodhouse <dwmw2@infradead.org>,
	Brian Norris <computersforpeace@gmail.com>,
	Boris Brezillon <boris.brezillon@free-electrons.com>,
	Marek Vasut <marek.vasut@gmail.com>,
	Richard Weinberger <richard@nod.at>,
	Cyrille Pitchen <cyrille.pitchen@atmel.com>,
	linux-mtd@lists.infradead.org
Subject: Re: [PATCH v2 00/53] Get rid of Docbook
Date: Fri, 23 Jun 2017 14:26:54 -0600	[thread overview]
Message-ID: <20170623142654.128ac5e3@lwn.net> (raw)
In-Reply-To: <C33A12EC-8748-4BB9-A7A2-023B1901AB4B@darmarit.de>

On Fri, 16 Jun 2017 16:03:23 +0200
Markus Heiser <markus.heiser@darmarit.de> wrote:

> I guess there are little remains lying around ;) what I have found:

I just committed the following to clean up that stuff, thanks.

jon

From 52b3f239bb692d9b3a68461798fb15c011e4108e Mon Sep 17 00:00:00 2001
From: Jonathan Corbet <corbet@lwn.net>
Date: Fri, 23 Jun 2017 14:17:38 -0600
Subject: [PATCH] Docs: clean up some DocBook loose ends

There were a few bits and pieces left over from the now-disused DocBook
toolchain; git rid of them.

Reported-by: Markus Heiser <markus.heiser@darmarit.de>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
---
 Documentation/dontdiff                    |   1 -
 Documentation/sphinx/convert_template.sed |  18 -
 Documentation/sphinx/post_convert.sed     |  23 -
 MAINTAINERS                               |   3 +-
 Makefile                                  |   1 -
 scripts/.gitignore                        |   1 -
 scripts/Makefile                          |   7 +-
 scripts/docproc.c                         | 681 ------------------------------
 scripts/kernel-doc-xml-ref                | 198 ---------
 9 files changed, 3 insertions(+), 930 deletions(-)
 delete mode 100644 Documentation/sphinx/convert_template.sed
 delete mode 100644 Documentation/sphinx/post_convert.sed
 delete mode 100644 scripts/docproc.c
 delete mode 100755 scripts/kernel-doc-xml-ref

diff --git a/Documentation/dontdiff b/Documentation/dontdiff
index 77b92221f951..f64a63b233c3 100644
--- a/Documentation/dontdiff
+++ b/Documentation/dontdiff
@@ -118,7 +118,6 @@ defkeymap.c
 devlist.h*
 devicetable-offsets.h
 dnotify_test
-docproc
 dslm
 dtc
 elf2ecoff
diff --git a/Documentation/sphinx/convert_template.sed b/Documentation/sphinx/convert_template.sed
deleted file mode 100644
index c1503fcca4ec..000000000000
--- a/Documentation/sphinx/convert_template.sed
+++ /dev/null
@@ -1,18 +0,0 @@
-#
-# Pandoc doesn't grok <function> or <structname>, so convert them
-# ahead of time.
-#
-# Use the following escapes to pass through pandoc:
-#	$bq = "`"
-#	$lt = "<"
-#	$gt = ">"
-#
-s%<function>\([^<(]\+\)()</function>%:c:func:$bq\1()$bq%g
-s%<function>\([^<(]\+\)</function>%:c:func:$bq\1()$bq%g
-s%<structname>struct *\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-s%struct <structname>\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-s%<structname>\([^<]\+\)</structname>%:c:type:$bqstruct \1 $lt\1$gt$bq%g
-#
-# Wrap docproc directives in para and code blocks.
-#
-s%^\(!.*\)$%<para><code>DOCPROC: \1</code></para>%
diff --git a/Documentation/sphinx/post_convert.sed b/Documentation/sphinx/post_convert.sed
deleted file mode 100644
index 392770bac53b..000000000000
--- a/Documentation/sphinx/post_convert.sed
+++ /dev/null
@@ -1,23 +0,0 @@
-#
-# Unescape.
-#
-s/$bq/`/g
-s/$lt/</g
-s/$gt/>/g
-#
-# pandoc thinks that both "_" needs to be escaped.  Remove the extra
-# backslashes.
-#
-s/\\_/_/g
-#
-# Unwrap docproc directives.
-#
-s/^``DOCPROC: !E\(.*\)``$/.. kernel-doc:: \1\n   :export:/
-s/^``DOCPROC: !I\(.*\)``$/.. kernel-doc:: \1\n   :internal:/
-s/^``DOCPROC: !F\([^ ]*\) \(.*\)``$/.. kernel-doc:: \1\n   :functions: \2/
-s/^``DOCPROC: !P\([^ ]*\) \(.*\)``$/.. kernel-doc:: \1\n   :doc: \2/
-s/^``DOCPROC: \(!.*\)``$/.. WARNING: DOCPROC directive not supported: \1/
-#
-# Trim trailing whitespace.
-#
-s/[[:space:]]*$//
diff --git a/MAINTAINERS b/MAINTAINERS
index 5df61e9757dc..12110616b2d2 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -4135,8 +4135,7 @@ M:	Jonathan Corbet <corbet@lwn.net>
 L:	linux-doc@vger.kernel.org
 S:	Maintained
 F:	Documentation/
-F:	scripts/docproc.c
-F:	scripts/kernel-doc*
+F:	scripts/kernel-doc
 X:	Documentation/ABI/
 X:	Documentation/devicetree/
 X:	Documentation/acpi
diff --git a/Makefile b/Makefile
index 855a48c41d61..dd1eb8d6c232 100644
--- a/Makefile
+++ b/Makefile
@@ -1467,7 +1467,6 @@ $(help-board-dirs): help-%:
 DOC_TARGETS := xmldocs sgmldocs psdocs latexdocs pdfdocs htmldocs mandocs installmandocs epubdocs cleandocs linkcheckdocs
 PHONY += $(DOC_TARGETS)
 $(DOC_TARGETS): scripts_basic FORCE
-	$(Q)$(MAKE) $(build)=scripts build_docproc
 	$(Q)$(MAKE) $(build)=Documentation $@
 
 else # KBUILD_EXTMOD
diff --git a/scripts/.gitignore b/scripts/.gitignore
index e063daa3ec4a..0442c06eefcb 100644
--- a/scripts/.gitignore
+++ b/scripts/.gitignore
@@ -7,7 +7,6 @@ pnmtologo
 unifdef
 ihex2fw
 recordmcount
-docproc
 check-lc_ctype
 sortextable
 asn1_compiler
diff --git a/scripts/Makefile b/scripts/Makefile
index 55550e4141c4..c06f4997d700 100644
--- a/scripts/Makefile
+++ b/scripts/Makefile
@@ -6,7 +6,6 @@
 # pnmttologo:    Convert pnm files to logo files
 # conmakehash:   Create chartable
 # conmakehash:	 Create arrays for initializing the kernel console tables
-# docproc:       Used in Documentation/
 
 HOST_EXTRACFLAGS += -I$(srctree)/tools/include
 
@@ -28,14 +27,12 @@ HOSTLOADLIBES_extract-cert = -lcrypto
 always		:= $(hostprogs-y) $(hostprogs-m)
 
 # The following hostprogs-y programs are only build on demand
-hostprogs-y += unifdef docproc
+hostprogs-y += unifdef
 
 # These targets are used internally to avoid "is up to date" messages
-PHONY += build_unifdef build_docproc
+PHONY += build_unifdef
 build_unifdef: $(obj)/unifdef
 	@:
-build_docproc: $(obj)/docproc
-	@:
 
 subdir-$(CONFIG_MODVERSIONS) += genksyms
 subdir-y                     += mod
diff --git a/scripts/docproc.c b/scripts/docproc.c
deleted file mode 100644
index 0a12593b9041..000000000000
--- a/scripts/docproc.c
+++ /dev/null
@@ -1,681 +0,0 @@
-/*
- *	docproc is a simple preprocessor for the template files
- *      used as placeholders for the kernel internal documentation.
- *	docproc is used for documentation-frontend and
- *      dependency-generator.
- *	The two usages have in common that they require
- *	some knowledge of the .tmpl syntax, therefore they
- *	are kept together.
- *
- *	documentation-frontend
- *		Scans the template file and call kernel-doc for
- *		all occurrences of ![EIF]file
- *		Beforehand each referenced file is scanned for
- *		any symbols that are exported via these macros:
- *			EXPORT_SYMBOL(), EXPORT_SYMBOL_GPL(), &
- *			EXPORT_SYMBOL_GPL_FUTURE()
- *		This is used to create proper -function and
- *		-nofunction arguments in calls to kernel-doc.
- *		Usage: docproc doc file.tmpl
- *
- *	dependency-generator:
- *		Scans the template file and list all files
- *		referenced in a format recognized by make.
- *		Usage:	docproc depend file.tmpl
- *		Writes dependency information to stdout
- *		in the following format:
- *		file.tmpl src.c	src2.c
- *		The filenames are obtained from the following constructs:
- *		!Efilename
- *		!Ifilename
- *		!Dfilename
- *		!Ffilename
- *		!Pfilename
- *
- */
-
-#define _GNU_SOURCE
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <ctype.h>
-#include <unistd.h>
-#include <limits.h>
-#include <errno.h>
-#include <getopt.h>
-#include <sys/types.h>
-#include <sys/wait.h>
-#include <time.h>
-
-/* exitstatus is used to keep track of any failing calls to kernel-doc,
- * but execution continues. */
-int exitstatus = 0;
-
-typedef void DFL(char *);
-DFL *defaultline;
-
-typedef void FILEONLY(char * file);
-FILEONLY *internalfunctions;
-FILEONLY *externalfunctions;
-FILEONLY *symbolsonly;
-FILEONLY *findall;
-
-typedef void FILELINE(char * file, char * line);
-FILELINE * singlefunctions;
-FILELINE * entity_system;
-FILELINE * docsection;
-
-#define MAXLINESZ     2048
-#define MAXFILES      250
-#define KERNELDOCPATH "scripts/"
-#define KERNELDOC     "kernel-doc"
-#define DOCBOOK       "-docbook"
-#define RST           "-rst"
-#define LIST          "-list"
-#define FUNCTION      "-function"
-#define NOFUNCTION    "-nofunction"
-#define NODOCSECTIONS "-no-doc-sections"
-#define SHOWNOTFOUND  "-show-not-found"
-
-enum file_format {
-	FORMAT_AUTO,
-	FORMAT_DOCBOOK,
-	FORMAT_RST,
-};
-
-static enum file_format file_format = FORMAT_AUTO;
-
-#define KERNELDOC_FORMAT	(file_format == FORMAT_RST ? RST : DOCBOOK)
-
-static char *srctree, *kernsrctree;
-
-static char **all_list = NULL;
-static int all_list_len = 0;
-
-static void consume_symbol(const char *sym)
-{
-	int i;
-
-	for (i = 0; i < all_list_len; i++) {
-		if (!all_list[i])
-			continue;
-		if (strcmp(sym, all_list[i]))
-			continue;
-		all_list[i] = NULL;
-		break;
-	}
-}
-
-static void usage (void)
-{
-	fprintf(stderr, "Usage: docproc [{--docbook|--rst}] {doc|depend} file\n");
-	fprintf(stderr, "Input is read from file.tmpl. Output is sent to stdout\n");
-	fprintf(stderr, "doc: frontend when generating kernel documentation\n");
-	fprintf(stderr, "depend: generate list of files referenced within file\n");
-	fprintf(stderr, "Environment variable SRCTREE: absolute path to sources.\n");
-	fprintf(stderr, "                     KBUILD_SRC: absolute path to kernel source tree.\n");
-}
-
-/*
- * Execute kernel-doc with parameters given in svec
- */
-static void exec_kernel_doc(char **svec)
-{
-	pid_t pid;
-	int ret;
-	char real_filename[PATH_MAX + 1];
-	/* Make sure output generated so far are flushed */
-	fflush(stdout);
-	switch (pid=fork()) {
-		case -1:
-			perror("fork");
-			exit(1);
-		case  0:
-			memset(real_filename, 0, sizeof(real_filename));
-			strncat(real_filename, kernsrctree, PATH_MAX);
-			strncat(real_filename, "/" KERNELDOCPATH KERNELDOC,
-					PATH_MAX - strlen(real_filename));
-			execvp(real_filename, svec);
-			fprintf(stderr, "exec ");
-			perror(real_filename);
-			exit(1);
-		default:
-			waitpid(pid, &ret ,0);
-	}
-	if (WIFEXITED(ret))
-		exitstatus |= WEXITSTATUS(ret);
-	else
-		exitstatus = 0xff;
-}
-
-/* Types used to create list of all exported symbols in a number of files */
-struct symbols
-{
-	char *name;
-};
-
-struct symfile
-{
-	char *filename;
-	struct symbols *symbollist;
-	int symbolcnt;
-};
-
-struct symfile symfilelist[MAXFILES];
-int symfilecnt = 0;
-
-static void add_new_symbol(struct symfile *sym, char * symname)
-{
-	sym->symbollist =
-	  realloc(sym->symbollist, (sym->symbolcnt + 1) * sizeof(char *));
-	sym->symbollist[sym->symbolcnt++].name = strdup(symname);
-}
-
-/* Add a filename to the list */
-static struct symfile * add_new_file(char * filename)
-{
-	symfilelist[symfilecnt++].filename = strdup(filename);
-	return &symfilelist[symfilecnt - 1];
-}
-
-/* Check if file already are present in the list */
-static struct symfile * filename_exist(char * filename)
-{
-	int i;
-	for (i=0; i < symfilecnt; i++)
-		if (strcmp(symfilelist[i].filename, filename) == 0)
-			return &symfilelist[i];
-	return NULL;
-}
-
-/*
- * List all files referenced within the template file.
- * Files are separated by tabs.
- */
-static void adddep(char * file)		   { printf("\t%s", file); }
-static void adddep2(char * file, char * line)     { line = line; adddep(file); }
-static void noaction(char * line)		   { line = line; }
-static void noaction2(char * file, char * line)   { file = file; line = line; }
-
-/* Echo the line without further action */
-static void printline(char * line)               { printf("%s", line); }
-
-/*
- * Find all symbols in filename that are exported with EXPORT_SYMBOL &
- * EXPORT_SYMBOL_GPL (& EXPORT_SYMBOL_GPL_FUTURE implicitly).
- * All symbols located are stored in symfilelist.
- */
-static void find_export_symbols(char * filename)
-{
-	FILE * fp;
-	struct symfile *sym;
-	char line[MAXLINESZ];
-	if (filename_exist(filename) == NULL) {
-		char real_filename[PATH_MAX + 1];
-		memset(real_filename, 0, sizeof(real_filename));
-		strncat(real_filename, srctree, PATH_MAX);
-		strncat(real_filename, "/", PATH_MAX - strlen(real_filename));
-		strncat(real_filename, filename,
-				PATH_MAX - strlen(real_filename));
-		sym = add_new_file(filename);
-		fp = fopen(real_filename, "r");
-		if (fp == NULL)	{
-			fprintf(stderr, "docproc: ");
-			perror(real_filename);
-			exit(1);
-		}
-		while (fgets(line, MAXLINESZ, fp)) {
-			char *p;
-			char *e;
-			if (((p = strstr(line, "EXPORT_SYMBOL_GPL")) != NULL) ||
-			    ((p = strstr(line, "EXPORT_SYMBOL")) != NULL)) {
-				/* Skip EXPORT_SYMBOL{_GPL} */
-				while (isalnum(*p) || *p == '_')
-					p++;
-				/* Remove parentheses & additional whitespace */
-				while (isspace(*p))
-					p++;
-				if (*p != '(')
-					continue; /* Syntax error? */
-				else
-					p++;
-				while (isspace(*p))
-					p++;
-				e = p;
-				while (isalnum(*e) || *e == '_')
-					e++;
-				*e = '\0';
-				add_new_symbol(sym, p);
-			}
-		}
-		fclose(fp);
-	}
-}
-
-/*
- * Document all external or internal functions in a file.
- * Call kernel-doc with following parameters:
- * kernel-doc [-docbook|-rst] -nofunction function_name1 filename
- * Function names are obtained from all the src files
- * by find_export_symbols.
- * intfunc uses -nofunction
- * extfunc uses -function
- */
-static void docfunctions(char * filename, char * type)
-{
-	int i,j;
-	int symcnt = 0;
-	int idx = 0;
-	char **vec;
-
-	for (i=0; i <= symfilecnt; i++)
-		symcnt += symfilelist[i].symbolcnt;
-	vec = malloc((2 + 2 * symcnt + 3) * sizeof(char *));
-	if (vec == NULL) {
-		perror("docproc: ");
-		exit(1);
-	}
-	vec[idx++] = KERNELDOC;
-	vec[idx++] = KERNELDOC_FORMAT;
-	vec[idx++] = NODOCSECTIONS;
-	for (i=0; i < symfilecnt; i++) {
-		struct symfile * sym = &symfilelist[i];
-		for (j=0; j < sym->symbolcnt; j++) {
-			vec[idx++]     = type;
-			consume_symbol(sym->symbollist[j].name);
-			vec[idx++] = sym->symbollist[j].name;
-		}
-	}
-	vec[idx++]     = filename;
-	vec[idx] = NULL;
-	if (file_format == FORMAT_RST)
-		printf(".. %s\n", filename);
-	else
-		printf("<!-- %s -->\n", filename);
-	exec_kernel_doc(vec);
-	fflush(stdout);
-	free(vec);
-}
-static void intfunc(char * filename) {	docfunctions(filename, NOFUNCTION); }
-static void extfunc(char * filename) { docfunctions(filename, FUNCTION);   }
-
-/*
- * Document specific function(s) in a file.
- * Call kernel-doc with the following parameters:
- * kernel-doc -docbook -function function1 [-function function2]
- */
-static void singfunc(char * filename, char * line)
-{
-	char *vec[200]; /* Enough for specific functions */
-	int i, idx = 0;
-	int startofsym = 1;
-	vec[idx++] = KERNELDOC;
-	vec[idx++] = KERNELDOC_FORMAT;
-	vec[idx++] = SHOWNOTFOUND;
-
-	/* Split line up in individual parameters preceded by FUNCTION */
-	for (i=0; line[i]; i++) {
-		if (isspace(line[i])) {
-			line[i] = '\0';
-			startofsym = 1;
-			continue;
-		}
-		if (startofsym) {
-			startofsym = 0;
-			vec[idx++] = FUNCTION;
-			vec[idx++] = &line[i];
-		}
-	}
-	for (i = 0; i < idx; i++) {
-		if (strcmp(vec[i], FUNCTION))
-			continue;
-		consume_symbol(vec[i + 1]);
-	}
-	vec[idx++] = filename;
-	vec[idx] = NULL;
-	exec_kernel_doc(vec);
-}
-
-/*
- * Insert specific documentation section from a file.
- * Call kernel-doc with the following parameters:
- * kernel-doc -docbook -function "doc section" filename
- */
-static void docsect(char *filename, char *line)
-{
-	/* kerneldoc -docbook -show-not-found -function "section" file NULL */
-	char *vec[7];
-	char *s;
-
-	for (s = line; *s; s++)
-		if (*s == '\n')
-			*s = '\0';
-
-	if (asprintf(&s, "DOC: %s", line) < 0) {
-		perror("asprintf");
-		exit(1);
-	}
-	consume_symbol(s);
-	free(s);
-
-	vec[0] = KERNELDOC;
-	vec[1] = KERNELDOC_FORMAT;
-	vec[2] = SHOWNOTFOUND;
-	vec[3] = FUNCTION;
-	vec[4] = line;
-	vec[5] = filename;
-	vec[6] = NULL;
-	exec_kernel_doc(vec);
-}
-
-static void find_all_symbols(char *filename)
-{
-	char *vec[4]; /* kerneldoc -list file NULL */
-	pid_t pid;
-	int ret, i, count, start;
-	char real_filename[PATH_MAX + 1];
-	int pipefd[2];
-	char *data, *str;
-	size_t data_len = 0;
-
-	vec[0] = KERNELDOC;
-	vec[1] = LIST;
-	vec[2] = filename;
-	vec[3] = NULL;
-
-	if (pipe(pipefd)) {
-		perror("pipe");
-		exit(1);
-	}
-
-	switch (pid=fork()) {
-		case -1:
-			perror("fork");
-			exit(1);
-		case  0:
-			close(pipefd[0]);
-			dup2(pipefd[1], 1);
-			memset(real_filename, 0, sizeof(real_filename));
-			strncat(real_filename, kernsrctree, PATH_MAX);
-			strncat(real_filename, "/" KERNELDOCPATH KERNELDOC,
-					PATH_MAX - strlen(real_filename));
-			execvp(real_filename, vec);
-			fprintf(stderr, "exec ");
-			perror(real_filename);
-			exit(1);
-		default:
-			close(pipefd[1]);
-			data = malloc(4096);
-			do {
-				while ((ret = read(pipefd[0],
-						   data + data_len,
-						   4096)) > 0) {
-					data_len += ret;
-					data = realloc(data, data_len + 4096);
-				}
-			} while (ret == -EAGAIN);
-			if (ret != 0) {
-				perror("read");
-				exit(1);
-			}
-			waitpid(pid, &ret ,0);
-	}
-	if (WIFEXITED(ret))
-		exitstatus |= WEXITSTATUS(ret);
-	else
-		exitstatus = 0xff;
-
-	count = 0;
-	/* poor man's strtok, but with counting */
-	for (i = 0; i < data_len; i++) {
-		if (data[i] == '\n') {
-			count++;
-			data[i] = '\0';
-		}
-	}
-	start = all_list_len;
-	all_list_len += count;
-	all_list = realloc(all_list, sizeof(char *) * all_list_len);
-	str = data;
-	for (i = 0; i < data_len && start != all_list_len; i++) {
-		if (data[i] == '\0') {
-			all_list[start] = str;
-			str = data + i + 1;
-			start++;
-		}
-	}
-}
-
-/*
- * Terminate s at first space, if any. If there was a space, return pointer to
- * the character after that. Otherwise, return pointer to the terminating NUL.
- */
-static char *chomp(char *s)
-{
-	while (*s && !isspace(*s))
-		s++;
-
-	if (*s)
-		*s++ = '\0';
-
-	return s;
-}
-
-/* Return pointer to directive content, or NULL if not a directive. */
-static char *is_directive(char *line)
-{
-	if (file_format == FORMAT_DOCBOOK && line[0] == '!')
-		return line + 1;
-	else if (file_format == FORMAT_RST && !strncmp(line, ".. !", 4))
-		return line + 4;
-
-	return NULL;
-}
-
-/*
- * Parse file, calling action specific functions for:
- * 1) Lines containing !E
- * 2) Lines containing !I
- * 3) Lines containing !D
- * 4) Lines containing !F
- * 5) Lines containing !P
- * 6) Lines containing !C
- * 7) Default lines - lines not matching the above
- */
-static void parse_file(FILE *infile)
-{
-	char line[MAXLINESZ];
-	char *p, *s;
-	while (fgets(line, MAXLINESZ, infile)) {
-		p = is_directive(line);
-		if (!p) {
-			defaultline(line);
-			continue;
-		}
-
-		switch (*p++) {
-		case 'E':
-			chomp(p);
-			externalfunctions(p);
-			break;
-		case 'I':
-			chomp(p);
-			internalfunctions(p);
-			break;
-		case 'D':
-			chomp(p);
-			symbolsonly(p);
-			break;
-		case 'F':
-			/* filename */
-			s = chomp(p);
-			/* function names */
-			while (isspace(*s))
-				s++;
-			singlefunctions(p, s);
-			break;
-		case 'P':
-			/* filename */
-			s = chomp(p);
-			/* DOC: section name */
-			while (isspace(*s))
-				s++;
-			docsection(p, s);
-			break;
-		case 'C':
-			chomp(p);
-			if (findall)
-				findall(p);
-			break;
-		default:
-			defaultline(line);
-		}
-	}
-	fflush(stdout);
-}
-
-/*
- * Is this a RestructuredText template?  Answer the question by seeing if its
- * name ends in ".rst".
- */
-static int is_rst(const char *file)
-{
-	char *dot = strrchr(file, '.');
-
-	return dot && !strcmp(dot + 1, "rst");
-}
-
-enum opts {
-	OPT_DOCBOOK,
-	OPT_RST,
-	OPT_HELP,
-};
-
-int main(int argc, char *argv[])
-{
-	const char *subcommand, *filename;
-	FILE * infile;
-	int i;
-
-	srctree = getenv("SRCTREE");
-	if (!srctree)
-		srctree = getcwd(NULL, 0);
-	kernsrctree = getenv("KBUILD_SRC");
-	if (!kernsrctree || !*kernsrctree)
-		kernsrctree = srctree;
-
-	for (;;) {
-		int c;
-		struct option opts[] = {
-			{ "docbook",	no_argument, NULL, OPT_DOCBOOK },
-			{ "rst",	no_argument, NULL, OPT_RST },
-			{ "help",	no_argument, NULL, OPT_HELP },
-			{}
-		};
-
-		c = getopt_long_only(argc, argv, "", opts, NULL);
-		if (c == -1)
-			break;
-
-		switch (c) {
-		case OPT_DOCBOOK:
-			file_format = FORMAT_DOCBOOK;
-			break;
-		case OPT_RST:
-			file_format = FORMAT_RST;
-			break;
-		case OPT_HELP:
-			usage();
-			return 0;
-		default:
-		case '?':
-			usage();
-			return 1;
-		}
-	}
-
-	argc -= optind;
-	argv += optind;
-
-	if (argc != 2) {
-		usage();
-		exit(1);
-	}
-
-	subcommand = argv[0];
-	filename = argv[1];
-
-	if (file_format == FORMAT_AUTO)
-		file_format = is_rst(filename) ? FORMAT_RST : FORMAT_DOCBOOK;
-
-	/* Open file, exit on error */
-	infile = fopen(filename, "r");
-	if (infile == NULL) {
-		fprintf(stderr, "docproc: ");
-		perror(filename);
-		exit(2);
-	}
-
-	if (strcmp("doc", subcommand) == 0) {
-		if (file_format == FORMAT_RST) {
-			time_t t = time(NULL);
-			printf(".. generated from %s by docproc %s\n",
-			       filename, ctime(&t));
-		}
-
-		/* Need to do this in two passes.
-		 * First pass is used to collect all symbols exported
-		 * in the various files;
-		 * Second pass generate the documentation.
-		 * This is required because some functions are declared
-		 * and exported in different files :-((
-		 */
-		/* Collect symbols */
-		defaultline       = noaction;
-		internalfunctions = find_export_symbols;
-		externalfunctions = find_export_symbols;
-		symbolsonly       = find_export_symbols;
-		singlefunctions   = noaction2;
-		docsection        = noaction2;
-		findall           = find_all_symbols;
-		parse_file(infile);
-
-		/* Rewind to start from beginning of file again */
-		fseek(infile, 0, SEEK_SET);
-		defaultline       = printline;
-		internalfunctions = intfunc;
-		externalfunctions = extfunc;
-		symbolsonly       = printline;
-		singlefunctions   = singfunc;
-		docsection        = docsect;
-		findall           = NULL;
-
-		parse_file(infile);
-
-		for (i = 0; i < all_list_len; i++) {
-			if (!all_list[i])
-				continue;
-			fprintf(stderr, "Warning: didn't use docs for %s\n",
-				all_list[i]);
-		}
-	} else if (strcmp("depend", subcommand) == 0) {
-		/* Create first part of dependency chain
-		 * file.tmpl */
-		printf("%s\t", filename);
-		defaultline       = noaction;
-		internalfunctions = adddep;
-		externalfunctions = adddep;
-		symbolsonly       = adddep;
-		singlefunctions   = adddep2;
-		docsection        = adddep2;
-		findall           = adddep;
-		parse_file(infile);
-		printf("\n");
-	} else {
-		fprintf(stderr, "Unknown option: %s\n", subcommand);
-		exit(1);
-	}
-	fclose(infile);
-	fflush(stdout);
-	return exitstatus;
-}
diff --git a/scripts/kernel-doc-xml-ref b/scripts/kernel-doc-xml-ref
deleted file mode 100755
index 104a5a5ba2c8..000000000000
--- a/scripts/kernel-doc-xml-ref
+++ /dev/null
@@ -1,198 +0,0 @@
-#!/usr/bin/perl -w
-
-use strict;
-
-## Copyright (C) 2015  Intel Corporation                         ##
-#                                                                ##
-## This software falls under the GNU General Public License.     ##
-## Please read the COPYING file for more information             ##
-#
-#
-# This software reads a XML file and a list of valid interal
-# references to replace Docbook tags with links.
-#
-# The list of "valid internal references" must be one-per-line in the following format:
-#      API-struct-foo
-#      API-enum-bar
-#      API-my-function
-#
-# The software walks over the XML file looking for xml tags representing possible references
-# to the Document. Each reference will be cross checked against the "Valid Internal Reference" list. If
-# the referece is found it replaces its content by a <link> tag.
-#
-# usage:
-# kernel-doc-xml-ref -db filename
-#		     xml filename > outputfile
-
-# read arguments
-if ($#ARGV != 2) {
-	usage();
-}
-
-#Holds the database filename
-my $databasefile;
-my @database;
-
-#holds the inputfile
-my $inputfile;
-my $errors = 0;
-
-my %highlights = (
-	"<function>(.*?)</function>",
-	    "\"<function>\" . convert_function(\$1, \$line) . \"</function>\"",
-	"<structname>(.*?)</structname>",
-	    "\"<structname>\" . convert_struct(\$1) . \"</structname>\"",
-	"<funcdef>(.*?)<function>(.*?)</function></funcdef>",
-	    "\"<funcdef>\" . convert_param(\$1) . \"<function>\$2</function></funcdef>\"",
-	"<paramdef>(.*?)<parameter>(.*?)</parameter></paramdef>",
-	    "\"<paramdef>\" . convert_param(\$1) . \"<parameter>\$2</parameter></paramdef>\"");
-
-while($ARGV[0] =~ m/^-(.*)/) {
-	my $cmd = shift @ARGV;
-	if ($cmd eq "-db") {
-		$databasefile = shift @ARGV
-	} else {
-		usage();
-	}
-}
-$inputfile = shift @ARGV;
-
-sub open_database {
-	open (my $handle, '<', $databasefile) or die "Cannot open $databasefile";
-	chomp(my @lines = <$handle>);
-	close $handle;
-
-	@database = @lines;
-}
-
-sub process_file {
-	open_database();
-
-	my $dohighlight;
-	foreach my $pattern (keys %highlights) {
-		$dohighlight .=  "\$line =~ s:$pattern:$highlights{$pattern}:eg;\n";
-	}
-
-	open(FILE, $inputfile) or die("Could not open $inputfile") or die ("Cannot open $inputfile");
-	foreach my $line (<FILE>)  {
-		eval $dohighlight;
-		print $line;
-	}
-}
-
-sub trim($_)
-{
-	my $str = $_[0];
-	$str =~ s/^\s+|\s+$//g;
-	return $str
-}
-
-sub has_key_defined($_)
-{
-	if ( grep( /^$_[0]$/, @database)) {
-		return 1;
-	}
-	return 0;
-}
-
-# Gets a <function> content and add it a hyperlink if possible.
-sub convert_function($_)
-{
-	my $arg = $_[0];
-	my $key = $_[0];
-
-	my $line = $_[1];
-
-	$key = trim($key);
-
-	$key =~ s/[^A-Za-z0-9]/-/g;
-	$key = "API-" . $key;
-
-	# We shouldn't add links to <funcdef> prototype
-	if (!has_key_defined($key) || $line =~ m/\s+<funcdef/i) {
-		return $arg;
-	}
-
-	my $head = $arg;
-	my $tail = "";
-	if ($arg =~ /(.*?)( ?)$/) {
-		$head = $1;
-		$tail = $2;
-	}
-	return "<link linkend=\"$key\">$head</link>$tail";
-}
-
-# Converting a struct text to link
-sub convert_struct($_)
-{
-	my $arg = $_[0];
-	my $key = $_[0];
-	$key =~ s/(struct )?(\w)/$2/g;
-	$key =~ s/[^A-Za-z0-9]/-/g;
-	$key = "API-struct-" . $key;
-
-	if (!has_key_defined($key)) {
-		return $arg;
-	}
-
-	my ($head, $tail) = split_pointer($arg);
-	return "<link linkend=\"$key\">$head</link>$tail";
-}
-
-# Identify "object *" elements
-sub split_pointer($_)
-{
-	my $arg = $_[0];
-	if ($arg =~ /(.*?)( ?\* ?)/) {
-		return ($1, $2);
-	}
-	return ($arg, "");
-}
-
-sub convert_param($_)
-{
-	my $type = $_[0];
-	my $keyname = convert_key_name($type);
-
-	if (!has_key_defined($keyname)) {
-		return $type;
-	}
-
-	my ($head, $tail) = split_pointer($type);
-	return "<link linkend=\"$keyname\">$head</link>$tail";
-
-}
-
-# DocBook links are in the API-<TYPE>-<STRUCT-NAME> format
-# This method gets an element and returns a valid DocBook reference for it.
-sub convert_key_name($_)
-{
-	#Pattern $2 is optional and might be uninitialized
-	no warnings 'uninitialized';
-
-	my $str = $_[0];
-	$str =~ s/(const|static)? ?(struct)? ?([a-zA-Z0-9_]+) ?(\*|&)?/$2 $3/g ;
-
-	# trim
-	$str =~ s/^\s+|\s+$//g;
-
-	# spaces and _ to -
-	$str =~ s/[^A-Za-z0-9]/-/g;
-
-	return "API-" . $str;
-}
-
-sub usage {
-	print "Usage: $0 -db database filename\n";
-	print "         xml source file(s) > outputfile\n";
-	exit 1;
-}
-
-# starting point
-process_file();
-
-if ($errors) {
-	print STDERR "$errors errors\n";
-}
-
-exit($errors);
-- 
2.13.1

  reply	other threads:[~2017-06-23 20:27 UTC|newest]

Thread overview: 105+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-05-16 12:15 [PATCH v2 00/53] Get rid of Docbook Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 01/53] docs-rst: convert kernel-hacking to ReST Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 02/53] kernel-hacking: update document Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 03/53] docs-rst: convert kernel-locking to ReST Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 04/53] mutex, futex: adjust kernel-doc markups to generate ReST Mauro Carvalho Chehab
2017-05-16 17:35   ` Darren Hart
2017-05-16 18:24     ` Mauro Carvalho Chehab
2017-05-16 18:24       ` Mauro Carvalho Chehab
2017-05-16 19:00       ` Darren Hart
2017-05-16 12:15 ` [PATCH v2 05/53] locking.rst: reformat locking table Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 06/53] locking.rst: add captions to two tables Mauro Carvalho Chehab
2017-05-16 12:15 ` [PATCH v2 07/53] locking.rst: Update some ReST markups Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 08/53] docs-rst: convert kgdb DocBook to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 09/53] kgdb.rst: Adjust ReST markups Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 10/53] conf.py: define a color for important markup on PDF output Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 11/53] docs-rst: conf.py: sort LaTeX documents in alphabetical order Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 12/53] docs-rst: conf.py: remove kernel-documentation from LaTeX Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 13/53] docs-rst: add crypto API book to pdf output Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 14/53] docs-rst: add dev-tools " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 15/53] docs-rst: add sound " Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 19:02   ` Takashi Iwai
2017-05-16 19:02     ` Takashi Iwai
2017-05-16 12:16 ` [PATCH v2 16/53] docs-rst: add userspace API " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 17/53] docs-rst: convert filesystems book to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 18/53] docs-rst: filesystems: use c domain references where needed Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 19/53] fs: jbd2: make jbd2_journal_start() kernel-doc parseable Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 20/53] docs-rst: don't ignore internal functions for jbd2 docs Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 21/53] fs: add a blank lines on some kernel-doc comments Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 22/53] fs: eventfd: fix identation on kernel-doc Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 23/53] fs: jbd2: escape a string with special chars on a kernel-doc Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 24/53] docs-rst: convert libata book to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 25/53] libata.rst: add c function and struct cross-references Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 26/53] libata: fix identation on a kernel-doc markup Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 27/53] docs-rst: convert s390-drivers DocBook to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 28/53] docs-rst: convert networking book " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 29/53] net: skbuff.h: properly escape a macro name on kernel-doc Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 30/53] net: fix some identation issues at kernel-doc markups Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 31/53] docs-rst: convert z8530book DocBook to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 32/53] docs-rst: convert scsi " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 33/53] scsi: fix some kernel-doc markups Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 34/53] docs-rst: convert w1 book to ReST Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 35/53] docs-rst: convert rapidio " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 36/53] docs-rst: convert librs " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 37/53] docs-rst: convert mtdnand " Mauro Carvalho Chehab
2017-05-16 13:11   ` Boris Brezillon
2017-05-16 12:16 ` [PATCH v2 38/53] mtdnand.rst: group the "::" with previous line Mauro Carvalho Chehab
2017-05-16 13:12   ` Boris Brezillon
2017-05-16 12:16 ` [PATCH v2 39/53] mtd: adjust kernel-docs to avoid Sphinx/kerneldoc warnings Mauro Carvalho Chehab
2017-05-16 13:13   ` Boris Brezillon
2017-05-16 12:16 ` [PATCH v2 40/53] docs-rst: convert sh book to ReST Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 41/53] docs-rst: convert lsm from DocBook " Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 42/53] docs: remove DocBook from the building system Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 43/53] docs: update old references for DocBook from the documentation Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:47   ` Bartlomiej Zolnierkiewicz
2017-05-16 12:47     ` Bartlomiej Zolnierkiewicz
2017-05-16 12:47     ` Bartlomiej Zolnierkiewicz
2017-05-17 16:51   ` Bjorn Helgaas
2017-05-17 16:51     ` Bjorn Helgaas
2017-05-17 16:51     ` Bjorn Helgaas
2017-05-16 12:16 ` [PATCH v2 44/53] MAINTAINERS: update old references for DocBook directory Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 45/53] ata: update references for libata documentation Mauro Carvalho Chehab
2017-05-16 12:47   ` Bartlomiej Zolnierkiewicz
2017-05-16 12:16 ` [PATCH v2 46/53] ia64, scsi: update references for the device-io book Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 47/53] irq: update genericirq book location Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 48/53] fs: update location of filesystems documentation Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 49/53] lib: update location of kgdb documentation Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 50/53] fs: fix the location of the kernel-api book Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 18:11     ` Mauro Carvalho Chehab
2017-05-16 12:16     ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 51/53] usb: fix the comment with regards to DocBook Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 18:11     ` Mauro Carvalho Chehab
2017-05-16 12:16     ` [v2,51/53] " Mauro Carvalho Chehab
2017-05-16 12:16     ` [PATCH v2 51/53] " Mauro Carvalho Chehab
2017-05-17 11:13     ` Felipe Balbi
2017-05-16 12:16 ` [PATCH v2 52/53] docs-rst: get rid of Documentation/sphinx/tmplcvt script Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 18:11     ` Mauro Carvalho Chehab
2017-05-16 12:16     ` Mauro Carvalho Chehab
2017-05-16 12:16 ` [PATCH v2 53/53] kernel-doc: describe the ``literal`` syntax Mauro Carvalho Chehab
2017-05-16 12:16   ` Mauro Carvalho Chehab
2017-05-16 18:12     ` Mauro Carvalho Chehab
2017-05-16 12:16     ` Mauro Carvalho Chehab
2018-06-06 16:31     ` Markus Heiser
2018-06-06 16:31       ` Markus Heiser
2017-05-16 12:38 ` [PATCH v2 30/53] net: fix some identation issues at kernel-doc markups David Howells
2017-05-16 12:38   ` David Howells
2017-05-18 17:26 ` [PATCH v2 00/53] Get rid of Docbook Jonathan Corbet
2017-05-18 23:01   ` Mauro Carvalho Chehab
2017-06-16 14:03     ` Markus Heiser
2017-06-16 14:03       ` Markus Heiser
2017-06-23 20:26       ` Jonathan Corbet [this message]
2017-06-23 20:26         ` Jonathan Corbet
2017-07-05 21:45       ` Jim Davis
2017-07-05 21:45         ` Jim Davis
2017-07-06  8:54         ` Markus Heiser
2017-07-06  8:54           ` Markus Heiser
2017-07-14 23:15           ` Jim Davis
2017-07-14 23:15             ` Jim Davis
2017-07-15  1:52             ` Mauro Carvalho Chehab
2017-07-15  1:52               ` Mauro Carvalho Chehab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170623142654.128ac5e3@lwn.net \
    --to=corbet@lwn.net \
    --cc=boris.brezillon@free-electrons.com \
    --cc=computersforpeace@gmail.com \
    --cc=cyrille.pitchen@atmel.com \
    --cc=dwmw2@infradead.org \
    --cc=jani.nikula@intel.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=marek.vasut@gmail.com \
    --cc=markus.heiser@darmarit.de \
    --cc=mchehab@infradead.org \
    --cc=mchehab@s-opensource.com \
    --cc=richard@nod.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.