From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755937AbYIORDb (ORCPT ); Mon, 15 Sep 2008 13:03:31 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753575AbYIORDX (ORCPT ); Mon, 15 Sep 2008 13:03:23 -0400 Received: from agminet01.oracle.com ([141.146.126.228]:32401 "EHLO agminet01.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753215AbYIORDW (ORCPT ); Mon, 15 Sep 2008 13:03:22 -0400 Date: Mon, 15 Sep 2008 10:02:29 -0700 From: Randy Dunlap To: lkml Cc: akpm , samr , Roland McGrath , Christoph Hellwig Subject: [PATCH] kernel-doc: allow structs whose members are all private Message-Id: <20080915100229.cf32f74e.randy.dunlap@oracle.com> Organization: Oracle Linux Eng. X-Mailer: Sylpheed 2.5.0 (GTK+ 2.12.0; x86_64-unknown-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Brightmail-Tracker: AAAAAQAAAAI= X-Brightmail-Tracker: AAAAAQAAAAI= X-Whitelist: TRUE X-Whitelist: TRUE Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Randy Dunlap Fix kernel-doc to handle structs whose members are all private; otherwise invalid XML is generated: xmlto: input does not validate (status 3) linux-2.6.27-rc6-git4/Documentation/DocBook/debugobjects.xml:146: element variablelist: validity error : Element variablelist content does not follow the DTD, expecting ((title , titleabbrev?)? , varlistentry+), got () Document linux-2.6.27-rc6-git4/Documentation/DocBook/debugobjects.xml does not validate make[1]: *** [Documentation/DocBook/debugobjects.html] Error 3 Signed-off-by: Randy Dunlap Reported-by: Roland McGrath cc: Roland McGrath cc: Christoph Hellwig --- scripts/kernel-doc | 4 ++++ 1 file changed, 4 insertions(+) --- linux-2.6.27-rc6-git4.orig/scripts/kernel-doc +++ linux-2.6.27-rc6-git4/scripts/kernel-doc @@ -781,6 +781,7 @@ sub output_struct_xml(%) { print " \n"; print " Members\n"; + if ($#{$args{'parameterlist'}} >= 0) { print " \n"; foreach $parameter (@{$args{'parameterlist'}}) { ($parameter =~ /^#/) && next; @@ -798,6 +799,9 @@ sub output_struct_xml(%) { print " \n"; } print " \n"; + } else { + print " \n None\n \n"; + } print " \n"; output_section_xml(@_);