Re: [patch 1/6] DocBook: changes and extensions to the kernel documentation

2005-04-06 Thread Jeff Garzik
Martin Waitz wrote:
--- linux-docbook.orig/drivers/video/fbmem.c	2005-04-06 12:13:12.674832161 +0200
+++ linux-docbook/drivers/video/fbmem.c	2005-04-06 12:24:11.946113964 +0200
@@ -1257,6 +1257,8 @@ int fb_new_modelist(struct fb_info *info
 static char *video_options[FB_MAX];
 static int ofonly;
 
+extern const char *global_mode_option;
+
 /**
  * fb_get_options - get kernel boot parameters
  * @name:   framebuffer name as it would appear in
@@ -1297,9 +1299,6 @@ int fb_get_options(char *name, char **op
 	return retval;
 }
 
-
-extern const char *global_mode_option;
-
 /**
  *	video_setup - process command line options
  *	@options: string of options
Index: linux-docbook/include/linux/skbuff.h
===
--- linux-docbook.orig/include/linux/skbuff.h	2005-04-06 12:13:12.677831708 +0200
+++ linux-docbook/include/linux/skbuff.h	2005-04-06 12:24:11.954112753 +0200
@@ -974,6 +974,7 @@ static inline void __skb_queue_purge(str
 		kfree_skb(skb);
 }
 
+#ifndef CONFIG_HAVE_ARCH_DEV_ALLOC_SKB
 /**
  *	__dev_alloc_skb - allocate an skbuff for sending
  *	@length: length to allocate
@@ -986,7 +987,6 @@ static inline void __skb_queue_purge(str
  *
  *	%NULL is returned in there is no free memory.
  */
-#ifndef CONFIG_HAVE_ARCH_DEV_ALLOC_SKB
 static inline struct sk_buff *__dev_alloc_skb(unsigned int length,
 	  int gfp_mask)
 {
Index: linux-docbook/mm/vmalloc.c
===
--- linux-docbook.orig/mm/vmalloc.c	2005-04-06 12:13:12.680831254 +0200
+++ linux-docbook/mm/vmalloc.c	2005-04-06 12:24:11.963111391 +0200
@@ -475,6 +475,10 @@ void *vmalloc(unsigned long size)
 
 EXPORT_SYMBOL(vmalloc);
 
+#ifndef PAGE_KERNEL_EXEC
+# define PAGE_KERNEL_EXEC PAGE_KERNEL
+#endif
+
 /**
  *	vmalloc_exec  -  allocate virtually contiguous, executable memory
  *
@@ -488,10 +492,6 @@ EXPORT_SYMBOL(vmalloc);
  *	use __vmalloc() instead.
  */
 
-#ifndef PAGE_KERNEL_EXEC
-# define PAGE_KERNEL_EXEC PAGE_KERNEL
-#endif
-
 void *vmalloc_exec(unsigned long size)
 {
 	return __vmalloc(size, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL_EXEC);

Although these patches do nothing but move code above a comment block, 
they make me worry/grumble, because the author clearly preferred the 
original code layout.

I'm -not- going to NAK this changeset, since it's not my code, but just 
pointing this out.  It would be nice if kernel-doc could grok this sort 
of stuff, but I understand why it can't (without parsing c/cpp).

ACK for the other changesets in your series.
Jeff
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[patch 1/6] DocBook: changes and extensions to the kernel documentation

2005-04-06 Thread Martin Waitz
DocBook: changes and extensions to the kernel documentation

From: Pavel Pisa <[EMAIL PROTECTED]>

I have recompiled Linux kernel 2.6.11.5 documentation for me and our
university students again.  The documentation could be extended for more
sources which are equipped by structured comments for recent 2.6 kernels. 
I have tried to proceed with that task.  I have done that more times from
2.6.0 time and it gets boring to do same changes again and again.  Linux
kernel compiles after changes for i386 and ARM targets.  I have added
references to some more files into kernel-api book, I have added some
section names as well.  So please, check that changes do not break
something and that categories are not too much skewed.

I have changed kernel-doc to accept "fastcall" and "asmlinkage" words
reserved by kernel convention.  Most of the other changes are modifications
in the comments to make kernel-doc happy, accept some parameters
description and do not bail out on errors.  Changed  to @pid in the
description, moved some #ifdef before comments to correct function to
comments bindings, etc.

You can see result of the modified documentation build at
  http://cmp.felk.cvut.cz/~pisa/linux/lkdb-2.6.11.tar.gz

Some more sources are ready to be included into kernel-doc generated
documentation.  Sources has been added into kernel-api for now.  Some more
section names added and probably some more chaos introduced as result of
quick cleanup work.

Signed-off-by: Pavel Pisa <[EMAIL PROTECTED]>
Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
Signed-off-by: Martin Waitz <[EMAIL PROTECTED]>

 Documentation/DocBook/kernel-api.tmpl |  186 --
 drivers/video/fbmem.c |5 
 fs/proc/base.c|   10 -
 include/linux/fs.h|   12 +-
 include/linux/net.h   |   38 +++---
 include/linux/skbuff.h|2 
 include/net/sock.h|  134 
 kernel/exit.c |2 
 kernel/power/swsusp.c |2 
 mm/page_alloc.c   |3 
 mm/vmalloc.c  |8 -
 net/core/datagram.c   |   28 ++---
 net/core/sock.c   |   12 +-
 net/core/stream.c |   12 +-
 net/sunrpc/xdr.c  |   12 +-
 scripts/kernel-doc|2 
 16 files changed, 320 insertions(+), 148 deletions(-)

Index: linux-docbook/Documentation/DocBook/kernel-api.tmpl
===
--- linux-docbook.orig/Documentation/DocBook/kernel-api.tmpl2005-04-06 
12:13:12.673832313 +0200
+++ linux-docbook/Documentation/DocBook/kernel-api.tmpl 2005-04-06 
12:24:11.943114418 +0200
@@ -49,13 +49,33 @@
 !Iinclude/asm-i386/unaligned.h
  
 
-
+
+ Kernel objects manipulation
+
+!Elib/kobject.c
+ 
+
+ Kernel utility functions
+!Iinclude/linux/kernel.h
+
+!Ekernel/panic.c
+!Ekernel/sys.c
+!Ekernel/rcupdate.c
+ 
+
   
 
   
@@ -81,7 +101,9 @@ KAO -->
 !Elib/vsprintf.c
  
  String Manipulation
-!Ilib/string.c
+
 !Elib/string.c
  
  Bit Operations
@@ -98,6 +120,25 @@ KAO -->
 !Iinclude/asm-i386/uaccess.h
 !Iarch/i386/lib/usercopy.c
  
+ More Memory Management Functions
+!Iinclude/linux/rmap.h
+!Emm/readahead.c
+!Emm/filemap.c
+!Emm/memory.c
+!Emm/vmalloc.c
+!Emm/mempool.c
+!Emm/page-writeback.c
+!Emm/truncate.c
+ 
+  
+
+
+  
+ Kernel IPC facilities
+
+ IPC utilities
+!Iipc/util.c
+ 
   
 
   
@@ -114,6 +155,10 @@ KAO -->
  sysctl interface
 !Ekernel/sysctl.c
  
+
+ proc filesystem interface
+!Ifs/proc/base.c
+ 
   
 
   
@@ -127,6 +172,10 @@ KAO -->
 
   
  The Linux VFS
+ The Filesystem types
+!Iinclude/linux/fs.h
+!Einclude/linux/fs.h
+ 
  The Directory Cache
 !Efs/dcache.c
 !Iinclude/linux/dcache.h
@@ -142,13 +191,31 @@ KAO -->
 !Efs/locks.c
 !Ifs/locks.c
  
+ Other Functions
+!Efs/mpage.c
+!Efs/namei.c
+!Efs/buffer.c
+!Efs/bio.c
+!Efs/seq_file.c
+!Efs/filesystems.c
+!Efs/fs-writeback.c
+!Efs/block_dev.c
+ 
   
 
   
  Linux Networking
+ Networking Base Types
+!Iinclude/linux/net.h
+ 
  Socket Buffer Functions
 !Iinclude/linux/skbuff.h
+!Iinclude/net/sock.h
+!Enet/socket.c
 !Enet/core/skbuff.c
+!Enet/core/sock.c
+!Enet/core/datagram.c
+!Enet/core/stream.c
  
  Socket Filter
 !Enet/core/filter.c
@@ -158,6 +225,14 @@ KAO -->
 !Enet/core/gen_stats.c
 !Enet/core/gen_estimator.c
  
+ SUN RPC subsystem
+
+!Enet/sunrpc/xdr.c
+!Enet/sunrpc/svcsock.c
+!Enet/sunrpc/sched.c
+ 
   
 
   
@@ -194,11 +269,26 @@ X!Ekernel/module.c
 !Iarch/i386/kernel/irq.c
  
 
+ Resources Management
+!Ekernel/resource.c
+ 
+
  MTRR Handling
 !Earch/i386/kernel/cpu/mtrr/main.c
  
  PCI Support Library
 !Edrivers/pci/pci.c
+!Edrivers/pci/pci-driver.c
+!Edrivers/pci/remove.c
+!Edrivers/pci/pci-acpi.c
+
+!Edriv