[PATCH] fixes for kernel with no procfs.

From: Dave Jones (dave@denial.force9.co.uk)
Date: Mon Apr 03 2000 - 16:16:26 EST


The following diff removes some compiler warnings of unused functions
and results in smaller kernel image when procfs is not compiled in.

More to follow..

Regards,

-- 
Dave.

diff -urN linux-2.3.99pre4/drivers/block/md.c linux-2.3.99pre4-dj/drivers/block/md.c --- linux-2.3.99pre4/drivers/block/md.c Mon Apr 3 19:08:54 2000 +++ linux-2.3.99pre4-dj/drivers/block/md.c Mon Apr 3 21:24:12 2000 @@ -2946,6 +2946,7 @@ return 0; } +#ifdef CONFIG_PROC_FS static int status_unused (char * page) { int sz = 0, i = 0; @@ -3106,6 +3107,7 @@ return sz; } +#endif /* CONFIG_PROC_FS */ int register_md_personality (int pnum, mdk_personality_t *p) { diff -urN linux-2.3.99pre4/net/802/tr.c linux-2.3.99pre4-dj/net/802/tr.c --- linux-2.3.99pre4/net/802/tr.c Thu Mar 30 20:13:13 2000 +++ linux-2.3.99pre4-dj/net/802/tr.c Mon Apr 3 21:39:44 2000 @@ -456,9 +456,7 @@ * routing. */ -#ifndef CONFIG_PROC_FS -static int rif_get_info(char *buffer,char **start, off_t offset, int length) {} -#else +#ifdef CONFIG_PROC_FS static int rif_get_info(char *buffer,char **start, off_t offset, int length) { int len=0; @@ -548,5 +546,7 @@ init_timer(&rif_timer); add_timer(&rif_timer); +#ifdef CONFIG_PROC_FS proc_net_create("tr_rif",0,rif_get_info); +#endif }

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Fri Apr 07 2000 - 21:00:10 EST