diff options
Diffstat (limited to 'scripts/kernel-doc')
-rwxr-xr-x | scripts/kernel-doc | 49 |
1 files changed, 40 insertions, 9 deletions
diff --git a/scripts/kernel-doc b/scripts/kernel-doc index 8b1dab63f11c..0835dc2a8aa9 100755 --- a/scripts/kernel-doc +++ b/scripts/kernel-doc @@ -553,15 +553,20 @@ sub output_section_xml(%) { # print out each section $lineprefix=" "; foreach $section (@{$args{'sectionlist'}}) { - print "<refsect1>\n <title>$section</title>\n <para>\n"; + print "<refsect1>\n"; + print "<title>$section</title>\n"; if ($section =~ m/EXAMPLE/i) { - print "<example><para>\n"; + print "<informalexample><programlisting>\n"; + } else { + print "<para>\n"; } output_highlight($args{'sections'}{$section}); if ($section =~ m/EXAMPLE/i) { - print "</para></example>\n"; + print "</programlisting></informalexample>\n"; + } else { + print "</para>\n"; } - print " </para>\n</refsect1>\n"; + print "</refsect1>\n"; } } @@ -576,8 +581,14 @@ sub output_function_xml(%) { $id =~ s/[^A-Za-z0-9]/-/g; print "<refentry>\n"; + print "<refentryinfo>\n"; + print " <title>LINUX</title>\n"; + print " <productname>Kernel Hackers Manual</productname>\n"; + print " <date>$man_date</date>\n"; + print "</refentryinfo>\n"; print "<refmeta>\n"; - print "<refentrytitle><phrase id=\"$id\">".$args{'function'}."</phrase></refentrytitle>\n"; + print " <refentrytitle><phrase id=\"$id\">".$args{'function'}."</phrase></refentrytitle>\n"; + print " <manvolnum>9</manvolnum>\n"; print "</refmeta>\n"; print "<refnamediv>\n"; print " <refname>".$args{'function'}."</refname>\n"; @@ -607,7 +618,7 @@ sub output_function_xml(%) { } } } else { - print " <void>\n"; + print " <void/>\n"; } print " </funcprototype></funcsynopsis>\n"; print "</refsynopsisdiv>\n"; @@ -646,8 +657,14 @@ sub output_struct_xml(%) { $id =~ s/[^A-Za-z0-9]/-/g; print "<refentry>\n"; + print "<refentryinfo>\n"; + print " <title>LINUX</title>\n"; + print " <productname>Kernel Hackers Manual</productname>\n"; + print " <date>$man_date</date>\n"; + print "</refentryinfo>\n"; print "<refmeta>\n"; - print "<refentrytitle><phrase id=\"$id\">".$args{'type'}." ".$args{'struct'}."</phrase></refentrytitle>\n"; + print " <refentrytitle><phrase id=\"$id\">".$args{'type'}." ".$args{'struct'}."</phrase></refentrytitle>\n"; + print " <manvolnum>9</manvolnum>\n"; print "</refmeta>\n"; print "<refnamediv>\n"; print " <refname>".$args{'type'}." ".$args{'struct'}."</refname>\n"; @@ -724,8 +741,14 @@ sub output_enum_xml(%) { $id =~ s/[^A-Za-z0-9]/-/g; print "<refentry>\n"; + print "<refentryinfo>\n"; + print " <title>LINUX</title>\n"; + print " <productname>Kernel Hackers Manual</productname>\n"; + print " <date>$man_date</date>\n"; + print "</refentryinfo>\n"; print "<refmeta>\n"; - print "<refentrytitle><phrase id=\"$id\">enum ".$args{'enum'}."</phrase></refentrytitle>\n"; + print " <refentrytitle><phrase id=\"$id\">enum ".$args{'enum'}."</phrase></refentrytitle>\n"; + print " <manvolnum>9</manvolnum>\n"; print "</refmeta>\n"; print "<refnamediv>\n"; print " <refname>enum ".$args{'enum'}."</refname>\n"; @@ -784,8 +807,14 @@ sub output_typedef_xml(%) { $id =~ s/[^A-Za-z0-9]/-/g; print "<refentry>\n"; + print "<refentryinfo>\n"; + print " <title>LINUX</title>\n"; + print " <productname>Kernel Hackers Manual</productname>\n"; + print " <date>$man_date</date>\n"; + print "</refentryinfo>\n"; print "<refmeta>\n"; - print "<refentrytitle><phrase id=\"$id\">typedef ".$args{'typedef'}."</phrase></refentrytitle>\n"; + print " <refentrytitle><phrase id=\"$id\">typedef ".$args{'typedef'}."</phrase></refentrytitle>\n"; + print " <manvolnum>9</manvolnum>\n"; print "</refmeta>\n"; print "<refnamediv>\n"; print " <refname>typedef ".$args{'typedef'}."</refname>\n"; @@ -1465,6 +1494,8 @@ sub dump_function($$) { $prototype =~ s/^static +//; $prototype =~ s/^extern +//; + $prototype =~ s/^fastcall +//; + $prototype =~ s/^asmlinkage +//; $prototype =~ s/^inline +//; $prototype =~ s/^__inline__ +//; $prototype =~ s/^#define +//; #ak added |