Linux Documentation
 help / color / mirror / Atom feed
* [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names
@ 2020-10-23  8:59 Mauro Carvalho Chehab
  2020-10-23 11:02 ` kernel test robot
  2020-10-23 11:24 ` kernel test robot
  0 siblings, 2 replies; 3+ messages in thread
From: Mauro Carvalho Chehab @ 2020-10-23  8:59 UTC (permalink / raw)
  To: Jonathan Corbet, Linux Doc Mailing List
  Cc: Mauro Carvalho Chehab, linux-kernel

Kernel-doc currently expects that the kernel-doc markup to come
just before the function/enum/struct/union/typedef prototype.

Yet, if it find things like:

	/**
	 * refcount_add - add a value to a refcount
	 * @i: the value to add to the refcount
	 * @r: the refcount
	 */
	static inline void __refcount_add(int i, refcount_t *r, int *oldp);
	static inline void refcount_add(int i, refcount_t *r);

Kernel-doc will do the wrong thing:

	foobar.h:6: warning: Function parameter or member 'oldp' not described in '__refcount_add'
	.. c:function:: void __refcount_add (int i, refcount_t *r, int *oldp)

	   add a value to a refcount

	**Parameters**

	``int i``
	  the value to add to the refcount

	``refcount_t *r``
	  the refcount

	``int *oldp``
	  *undescribed*

Basically, it will document "__refcount_add" with the kernel-doc
markup for refcount_add.

If both functions have the same arguments, this won't even
produce any warning!

Add a logic to check if the kernel-doc identifier matches the actual
name of the C function or data structure that will be documented.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 scripts/kernel-doc | 56 +++++++++++++++++++++++++++++++++-------------
 1 file changed, 40 insertions(+), 16 deletions(-)

diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index 99cd8418ff8a..7ffc54dfa5a0 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -382,6 +382,9 @@ my $inline_doc_state;
 # 'function', 'struct', 'union', 'enum', 'typedef'
 my $decl_type;
 
+# Name of the kernel-doc identifier for non-DOC markups
+my $identifier;
+
 my $doc_start = '^/\*\*\s*$'; # Allow whitespace at end of comment start.
 my $doc_end = '\*/';
 my $doc_com = '\s*\*\s*';
@@ -1203,6 +1206,11 @@ sub dump_struct($$) {
 	$declaration_name = $2;
 	my $members = $3;
 
+	if ($identifier ne $declaration_name) {
+	    print STDERR "${file}:$.: warning: expecting prototype for $decl_type $identifier. Prototype was for $decl_type $declaration_name instead\n";
+	    return;
+	}
+
 	# ignore members marked private:
 	$members =~ s/\/\*\s*private:.*?\/\*\s*public:.*?\*\///gosi;
 	$members =~ s/\/\*\s*private:.*//gosi;
@@ -1391,6 +1399,11 @@ sub dump_enum($$) {
     }
 
     if ($declaration_name) {
+	if ($identifier ne $declaration_name) {
+	    print STDERR "${file}:$.: warning: expecting prototype for enum $identifier. Prototype was for enum $declaration_name instead\n";
+	    return;
+	}
+
 	my %_members;
 
 	$members =~ s/\s+$//;
@@ -1446,6 +1459,11 @@ sub dump_typedef($$) {
 	$declaration_name = $2;
 	my $args = $3;
 
+	if ($identifier ne $declaration_name) {
+	    print STDERR "${file}:$.: warning: expecting prototype for typedef $identifier. Prototype was for typedef $declaration_name instead\n";
+	    return;
+	}
+
 	create_parameterlist($args, ',', $file, $declaration_name);
 
 	output_declaration($declaration_name,
@@ -1791,6 +1809,11 @@ sub dump_function($$) {
 	return;
     }
 
+    if ($identifier ne $declaration_name) {
+	print STDERR "${file}:$.: warning: expecting prototype for $identifier(). Prototype was for $declaration_name() instead\n";
+	return;
+    }
+
     my $prms = join " ", @parameterlist;
     check_sections($file, $declaration_name, "function", $sectcheck, $prms);
 
@@ -2036,7 +2059,6 @@ sub process_normal() {
 #
 sub process_name($$) {
     my $file = shift;
-    my $identifier;
     my $descr;
 
     if (/$doc_block/o) {
@@ -2049,12 +2071,19 @@ sub process_name($$) {
 	} else {
 	    $section = $1;
 	}
-    }
-    elsif (/$doc_decl/o) {
+    } elsif (/$doc_decl/o) {
 	$identifier = $1;
-	if (/\s*([\w\s]+?)(\(\))?\s*-/) {
+	if (/\s*([\w\s]+?)(\(\))?\s*([-:].*)?$/) {
 	    $identifier = $1;
 	}
+	if ($identifier =~ m/^(struct|union|enum|typedef)\b\s*(\S*)/) {
+	    $decl_type = $1;
+	    $identifier = $2;
+	} else {
+	    $decl_type = 'function';
+	    $identifier =~ s/\(\)//;
+	}
+	$identifier =~ s/\s+$//;
 
 	$state = STATE_BODY;
 	# if there's no @param blocks need to set up default section
@@ -2062,7 +2091,7 @@ sub process_name($$) {
 	$contents = "";
 	$section = $section_default;
 	$new_start_line = $. + 1;
-	if (/-(.*)/) {
+	if (/[-:](.*)/) {
 	    # strip leading/trailing/multiple spaces
 	    $descr= $1;
 	    $descr =~ s/^\s*//;
@@ -2080,20 +2109,15 @@ sub process_name($$) {
 	    ++$warnings;
 	}
 
-	if ($identifier =~ m/^struct\b/) {
-	    $decl_type = 'struct';
-	} elsif ($identifier =~ m/^union\b/) {
-	    $decl_type = 'union';
-	} elsif ($identifier =~ m/^enum\b/) {
-	    $decl_type = 'enum';
-	} elsif ($identifier =~ m/^typedef\b/) {
-	    $decl_type = 'typedef';
-	} else {
-	    $decl_type = 'function';
+	if ($identifier eq "") {
+	    print STDERR "${file}:$.: warning: wrong kernel-doc identifier on line:\n";
+	    print STDERR $_;
+	    ++$warnings;
+	    $state = STATE_NORMAL;
 	}
 
 	if ($verbose) {
-	    print STDERR "${file}:$.: info: Scanning doc for $identifier\n";
+	    print STDERR "${file}:$.: info: Scanning doc for $decl_type $identifier\n";
 	}
     } else {
 	print STDERR "${file}:$.: warning: Cannot understand $_ on line $.",
-- 
2.26.2


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

* Re: [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names
  2020-10-23  8:59 [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names Mauro Carvalho Chehab
@ 2020-10-23 11:02 ` kernel test robot
  2020-10-23 11:24 ` kernel test robot
  1 sibling, 0 replies; 3+ messages in thread
From: kernel test robot @ 2020-10-23 11:02 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Jonathan Corbet, Linux Doc Mailing List
  Cc: kbuild-all, linux-media, Mauro Carvalho Chehab, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 12185 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on next-20201023]
[cannot apply to lwn/docs-next linux/master v5.9]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/kernel-doc-validate-kernel-doc-markup-with-the-actual-names/20201023-170132
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git f9893351acaecf0a414baf9942b48d5bb5c688c6
config: nds32-defconfig (attached as .config)
compiler: nds32le-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/0day-ci/linux/commit/234e4a9d3907dbf2a71da9a2f49007e19d2a2e68
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Mauro-Carvalho-Chehab/kernel-doc-validate-kernel-doc-markup-with-the-actual-names/20201023-170132
        git checkout 234e4a9d3907dbf2a71da9a2f49007e19d2a2e68
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=nds32 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   kernel/cpu.c:56: warning: cannot understand function prototype: 'struct cpuhp_cpu_state '
   kernel/cpu.c:113: warning: cannot understand function prototype: 'struct cpuhp_step '
>> kernel/cpu.c:151: warning: expecting prototype for cpuhp_invoke_callback _ Invoke the callbacks for a given state(). Prototype was for cpuhp_invoke_callback() instead
>> kernel/cpu.c:1142: warning: wrong kernel-doc identifier on line:
    * notify_cpu_starting(cpu) - Invoke the callbacks on the starting CPU
   kernel/cpu.c:1884: warning: Function parameter or member 'name' not described in '__cpuhp_setup_state_cpuslocked'
--
   kernel/fork.c:1134: warning: Function parameter or member 'mm' not described in 'set_mm_exe_file'
   kernel/fork.c:1134: warning: Function parameter or member 'new_exe_file' not described in 'set_mm_exe_file'
   kernel/fork.c:1158: warning: Function parameter or member 'mm' not described in 'get_mm_exe_file'
   kernel/fork.c:1178: warning: Function parameter or member 'task' not described in 'get_task_exe_file'
   kernel/fork.c:1203: warning: Function parameter or member 'task' not described in 'get_task_mm'
>> kernel/fork.c:2716: warning: expecting prototype for clone3(). Prototype was for sys_clone3() instead
--
>> kernel/resource.c:344: warning: expecting prototype for The(). Prototype was for find_next_iomem_res() instead
>> kernel/resource.c:436: warning: expecting prototype for with matching resource(). Prototype was for walk_iomem_res_desc() instead
--
>> kernel/pid.c:585: warning: expecting prototype for pidfd_open(). Prototype was for sys_pidfd_open() instead
--
   mm/truncate.c:646: warning: Function parameter or member 'mapping' not described in 'invalidate_mapping_pagevec'
   mm/truncate.c:646: warning: Function parameter or member 'start' not described in 'invalidate_mapping_pagevec'
   mm/truncate.c:646: warning: Function parameter or member 'end' not described in 'invalidate_mapping_pagevec'
   mm/truncate.c:646: warning: Function parameter or member 'nr_pagevec' not described in 'invalidate_mapping_pagevec'
>> mm/truncate.c:646: warning: expecting prototype for except that it accounts for pages(). Prototype was for invalidate_mapping_pagevec() instead
--
>> mm/vmscan.c:1652: warning: expecting prototype for pgdat(). Prototype was for isolate_lru_pages() instead
--
>> mm/gup.c:1963: warning: expecting prototype for is suitable to replace the form(). Prototype was for get_user_pages_locked() instead
--
>> mm/page_alloc.c:510: warning: expecting prototype for get_pfnblock_flags_mask(). Prototype was for __get_pfnblock_flags_mask() instead
--
   fs/open.c:887: warning: Excess function parameter 'opened' description in 'finish_open'
   fs/open.c:929: warning: Excess function parameter 'cred' description in 'vfs_open'
>> fs/open.c:1320: warning: expecting prototype for close_range(). Prototype was for sys_close_range() instead
--
>> fs/super.c:1830: warning: expecting prototype for thaw_super(). Prototype was for thaw_super_locked() instead
--
>> fs/ioctl.c:109: warning: expecting prototype for fiemap_fill_next_extent(). Prototype was for SET_UNKNOWN_FLAGS() instead
   fs/ioctl.c:785: warning: Function parameter or member 'file' not described in 'compat_ptr_ioctl'
   fs/ioctl.c:785: warning: Function parameter or member 'cmd' not described in 'compat_ptr_ioctl'
   fs/ioctl.c:785: warning: Function parameter or member 'arg' not described in 'compat_ptr_ioctl'
..

vim +151 kernel/cpu.c

a724632ca0c84b4 Thomas Gleixner 2016-08-12  137  
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  138  /**
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  139   * cpuhp_invoke_callback _ Invoke the callbacks for a given state
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  140   * @cpu:	The cpu for which the callback should be invoked
96abb968549cdef Peter Zijlstra  2017-09-20  141   * @state:	The state to do callbacks for
a724632ca0c84b4 Thomas Gleixner 2016-08-12  142   * @bringup:	True if the bringup callback should be invoked
96abb968549cdef Peter Zijlstra  2017-09-20  143   * @node:	For multi-instance, do a single entry callback for install/remove
96abb968549cdef Peter Zijlstra  2017-09-20  144   * @lastp:	For multi-instance rollback, remember how far we got
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  145   *
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  146   * Called from cpu hotplug and from the state register machinery.
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  147   */
a724632ca0c84b4 Thomas Gleixner 2016-08-12  148  static int cpuhp_invoke_callback(unsigned int cpu, enum cpuhp_state state,
96abb968549cdef Peter Zijlstra  2017-09-20  149  				 bool bringup, struct hlist_node *node,
96abb968549cdef Peter Zijlstra  2017-09-20  150  				 struct hlist_node **lastp)
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26 @151  {
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  152  	struct cpuhp_cpu_state *st = per_cpu_ptr(&cpuhp_state, cpu);
a724632ca0c84b4 Thomas Gleixner 2016-08-12  153  	struct cpuhp_step *step = cpuhp_get_step(state);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  154  	int (*cbm)(unsigned int cpu, struct hlist_node *node);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  155  	int (*cb)(unsigned int cpu);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  156  	int ret, cnt;
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  157  
1db49484f21ed0f Peter Zijlstra  2017-09-20  158  	if (st->fail == state) {
1db49484f21ed0f Peter Zijlstra  2017-09-20  159  		st->fail = CPUHP_INVALID;
1db49484f21ed0f Peter Zijlstra  2017-09-20  160  
1db49484f21ed0f Peter Zijlstra  2017-09-20  161  		if (!(bringup ? step->startup.single : step->teardown.single))
1db49484f21ed0f Peter Zijlstra  2017-09-20  162  			return 0;
1db49484f21ed0f Peter Zijlstra  2017-09-20  163  
1db49484f21ed0f Peter Zijlstra  2017-09-20  164  		return -EAGAIN;
1db49484f21ed0f Peter Zijlstra  2017-09-20  165  	}
1db49484f21ed0f Peter Zijlstra  2017-09-20  166  
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  167  	if (!step->multi_instance) {
96abb968549cdef Peter Zijlstra  2017-09-20  168  		WARN_ON_ONCE(lastp && *lastp);
3c1627e999e45e2 Thomas Gleixner 2016-09-05  169  		cb = bringup ? step->startup.single : step->teardown.single;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  170  		if (!cb)
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  171  			return 0;
a724632ca0c84b4 Thomas Gleixner 2016-08-12  172  		trace_cpuhp_enter(cpu, st->target, state, cb);
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  173  		ret = cb(cpu);
a724632ca0c84b4 Thomas Gleixner 2016-08-12  174  		trace_cpuhp_exit(cpu, st->state, state, ret);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  175  		return ret;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  176  	}
3c1627e999e45e2 Thomas Gleixner 2016-09-05  177  	cbm = bringup ? step->startup.multi : step->teardown.multi;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  178  	if (!cbm)
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  179  		return 0;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  180  
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  181  	/* Single invocation for instance add/remove */
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  182  	if (node) {
96abb968549cdef Peter Zijlstra  2017-09-20  183  		WARN_ON_ONCE(lastp && *lastp);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  184  		trace_cpuhp_multi_enter(cpu, st->target, state, cbm, node);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  185  		ret = cbm(cpu, node);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  186  		trace_cpuhp_exit(cpu, st->state, state, ret);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  187  		return ret;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  188  	}
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  189  
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  190  	/* State transition. Invoke on all instances */
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  191  	cnt = 0;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  192  	hlist_for_each(node, &step->list) {
96abb968549cdef Peter Zijlstra  2017-09-20  193  		if (lastp && node == *lastp)
96abb968549cdef Peter Zijlstra  2017-09-20  194  			break;
96abb968549cdef Peter Zijlstra  2017-09-20  195  
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  196  		trace_cpuhp_multi_enter(cpu, st->target, state, cbm, node);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  197  		ret = cbm(cpu, node);
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  198  		trace_cpuhp_exit(cpu, st->state, state, ret);
96abb968549cdef Peter Zijlstra  2017-09-20  199  		if (ret) {
96abb968549cdef Peter Zijlstra  2017-09-20  200  			if (!lastp)
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  201  				goto err;
96abb968549cdef Peter Zijlstra  2017-09-20  202  
96abb968549cdef Peter Zijlstra  2017-09-20  203  			*lastp = node;
96abb968549cdef Peter Zijlstra  2017-09-20  204  			return ret;
96abb968549cdef Peter Zijlstra  2017-09-20  205  		}
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  206  		cnt++;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  207  	}
96abb968549cdef Peter Zijlstra  2017-09-20  208  	if (lastp)
96abb968549cdef Peter Zijlstra  2017-09-20  209  		*lastp = NULL;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  210  	return 0;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  211  err:
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  212  	/* Rollback the instances if one failed */
3c1627e999e45e2 Thomas Gleixner 2016-09-05  213  	cbm = !bringup ? step->startup.multi : step->teardown.multi;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  214  	if (!cbm)
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  215  		return ret;
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  216  
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  217  	hlist_for_each(node, &step->list) {
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  218  		if (!cnt--)
cf392d10b69e6e6 Thomas Gleixner 2016-08-12  219  			break;
724a86881d03ee5 Peter Zijlstra  2017-09-20  220  
724a86881d03ee5 Peter Zijlstra  2017-09-20  221  		trace_cpuhp_multi_enter(cpu, st->target, state, cbm, node);
724a86881d03ee5 Peter Zijlstra  2017-09-20  222  		ret = cbm(cpu, node);
724a86881d03ee5 Peter Zijlstra  2017-09-20  223  		trace_cpuhp_exit(cpu, st->state, state, ret);
724a86881d03ee5 Peter Zijlstra  2017-09-20  224  		/*
724a86881d03ee5 Peter Zijlstra  2017-09-20  225  		 * Rollback must not fail,
724a86881d03ee5 Peter Zijlstra  2017-09-20  226  		 */
724a86881d03ee5 Peter Zijlstra  2017-09-20  227  		WARN_ON_ONCE(ret);
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  228  	}
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  229  	return ret;
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  230  }
cff7d378d3fdbb5 Thomas Gleixner 2016-02-26  231  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 10938 bytes --]

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

* Re: [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names
  2020-10-23  8:59 [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names Mauro Carvalho Chehab
  2020-10-23 11:02 ` kernel test robot
@ 2020-10-23 11:24 ` kernel test robot
  1 sibling, 0 replies; 3+ messages in thread
From: kernel test robot @ 2020-10-23 11:24 UTC (permalink / raw)
  To: Mauro Carvalho Chehab, Jonathan Corbet, Linux Doc Mailing List
  Cc: kbuild-all, linux-media, Mauro Carvalho Chehab, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 4058 bytes --]

Hi Mauro,

I love your patch! Perhaps something to improve:

[auto build test WARNING on linus/master]
[also build test WARNING on next-20201023]
[cannot apply to lwn/docs-next linux/master v5.9]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url:    https://github.com/0day-ci/linux/commits/Mauro-Carvalho-Chehab/kernel-doc-validate-kernel-doc-markup-with-the-actual-names/20201023-170132
base:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git f9893351acaecf0a414baf9942b48d5bb5c688c6
config: parisc-defconfig (attached as .config)
compiler: hppa-linux-gcc (GCC) 9.3.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/0day-ci/linux/commit/234e4a9d3907dbf2a71da9a2f49007e19d2a2e68
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Mauro-Carvalho-Chehab/kernel-doc-validate-kernel-doc-markup-with-the-actual-names/20201023-170132
        git checkout 234e4a9d3907dbf2a71da9a2f49007e19d2a2e68
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=parisc 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   drivers/tty/serial/mux.c:118: warning: Function parameter or member 'port' not described in 'mux_set_mctrl'
   drivers/tty/serial/mux.c:118: warning: Excess function parameter 'ports' description in 'mux_set_mctrl'
>> drivers/tty/serial/mux.c:371: warning: expecting prototype for mux_drv_poll(). Prototype was for mux_poll() instead

vim +371 drivers/tty/serial/mux.c

^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  363  
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  364  /**
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  365   * mux_drv_poll - Mux poll function.
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  366   * @unused: Unused variable
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  367   *
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  368   * This function periodically polls the Serial MUX to check for new data.
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  369   */
e99e88a9d2b0674 drivers/tty/serial/mux.c Kees Cook      2017-10-16  370  static void mux_poll(struct timer_list *unused)
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16 @371  {  
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  372  	int i;
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  373  
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  374  	for(i = 0; i < port_cnt; ++i) {
4bd5d82779466a2 drivers/serial/mux.c     Ryan Bradetich 2006-11-03  375  		if(!mux_ports[i].enabled)
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  376  			continue;
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  377  
4bd5d82779466a2 drivers/serial/mux.c     Ryan Bradetich 2006-11-03  378  		mux_read(&mux_ports[i].port);
4bd5d82779466a2 drivers/serial/mux.c     Ryan Bradetich 2006-11-03  379  		mux_write(&mux_ports[i].port);
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  380  	}
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  381  
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  382  	mod_timer(&mux_timer, jiffies + MUX_POLL_DELAY);
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  383  }
^1da177e4c3f415 drivers/serial/mux.c     Linus Torvalds 2005-04-16  384  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 18434 bytes --]

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

end of thread, other threads:[~2020-10-23 11:25 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-23  8:59 [PATCH v2] kernel-doc: validate kernel-doc markup with the actual names Mauro Carvalho Chehab
2020-10-23 11:02 ` kernel test robot
2020-10-23 11:24 ` kernel test robot

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