* [2.6 patch] fs/drop_caches.c: make 2 functions static
@ 2008-02-17 8:17 Adrian Bunk
2008-02-18 13:01 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: Adrian Bunk @ 2008-02-17 8:17 UTC (permalink / raw)
To: Andrew Morton; +Cc: linux-kernel
This patch makes the following needlessly global functions static:
- drop_pagecache()
- drop_slab()
Signed-off-by: Adrian Bunk <bunk@kernel.org>
---
fs/drop_caches.c | 4 ++--
include/linux/mm.h | 2 --
2 files changed, 2 insertions(+), 4 deletions(-)
32191754eb7aed31406850a082565bc428268a08 diff --git a/fs/drop_caches.c b/fs/drop_caches.c
index 59375ef..e2c6b65 100644
--- a/fs/drop_caches.c
+++ b/fs/drop_caches.c
@@ -25,7 +25,7 @@ static void drop_pagecache_sb(struct super_block *sb)
spin_unlock(&inode_lock);
}
-void drop_pagecache(void)
+static void drop_pagecache(void)
{
struct super_block *sb;
@@ -45,7 +45,7 @@ restart:
spin_unlock(&sb_lock);
}
-void drop_slab(void)
+static void drop_slab(void)
{
int nr_objects;
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 26c7124..48927d4 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -1192,8 +1192,6 @@ int drop_caches_sysctl_handler(struct ctl_table *, int, struct file *,
void __user *, size_t *, loff_t *);
unsigned long shrink_slab(unsigned long scanned, gfp_t gfp_mask,
unsigned long lru_pages);
-void drop_pagecache(void);
-void drop_slab(void);
#ifndef CONFIG_MMU
#define randomize_va_space 0
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [2.6 patch] fs/drop_caches.c: make 2 functions static
2008-02-17 8:17 [2.6 patch] fs/drop_caches.c: make 2 functions static Adrian Bunk
@ 2008-02-18 13:01 ` Andrew Morton
2008-02-18 21:45 ` Neil Brown
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2008-02-18 13:01 UTC (permalink / raw)
To: Adrian Bunk; +Cc: linux-kernel, Neil Brown
On Sun, 17 Feb 2008 10:17:46 +0200 Adrian Bunk <bunk@kernel.org> wrote:
> This patch makes the following needlessly global functions static:
> - drop_pagecache()
> - drop_slab()
>
> Signed-off-by: Adrian Bunk <bunk@kernel.org>
>
> ---
>
> fs/drop_caches.c | 4 ++--
> include/linux/mm.h | 2 --
> 2 files changed, 2 insertions(+), 4 deletions(-)
>
> 32191754eb7aed31406850a082565bc428268a08 diff --git a/fs/drop_caches.c b/fs/drop_caches.c
> index 59375ef..e2c6b65 100644
> --- a/fs/drop_caches.c
> +++ b/fs/drop_caches.c
> @@ -25,7 +25,7 @@ static void drop_pagecache_sb(struct super_block *sb)
> spin_unlock(&inode_lock);
> }
>
> -void drop_pagecache(void)
> +static void drop_pagecache(void)
> {
> struct super_block *sb;
>
> @@ -45,7 +45,7 @@ restart:
> spin_unlock(&sb_lock);
> }
>
> -void drop_slab(void)
> +static void drop_slab(void)
> {
> int nr_objects;
>
This was originally done because Neil said that he planned to use these in
nfsd. I guess that didn't happen, and an additional patch would be needed
here anyway to do the module exports. So.... zap.
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [2.6 patch] fs/drop_caches.c: make 2 functions static
2008-02-18 13:01 ` Andrew Morton
@ 2008-02-18 21:45 ` Neil Brown
0 siblings, 0 replies; 3+ messages in thread
From: Neil Brown @ 2008-02-18 21:45 UTC (permalink / raw)
To: Andrew Morton; +Cc: Adrian Bunk, linux-kernel
On Monday February 18, akpm@linux-foundation.org wrote:
> On Sun, 17 Feb 2008 10:17:46 +0200 Adrian Bunk <bunk@kernel.org> wrote:
>
> > This patch makes the following needlessly global functions static:
> > - drop_pagecache()
> > - drop_slab()
> >
> > Signed-off-by: Adrian Bunk <bunk@kernel.org>
..
>
> This was originally done because Neil said that he planned to use these in
> nfsd. I guess that didn't happen, and an additional patch would be needed
> here anyway to do the module exports. So.... zap.
Did I? I wonder why. Neither my memory or my mail archive gives me
any hints, so I suspect it must have just been a passing fancy that
resolved into a really dumb idea (as so many passing fancies do).
Zap-supported-by: NeilBrown <neilb@suse.de>
Hmmm... I guess that should really be
Acked-By: NeilBrown <neilb@suse.de>
;-)
NeilBrown
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2008-02-18 21:45 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-17 8:17 [2.6 patch] fs/drop_caches.c: make 2 functions static Adrian Bunk
2008-02-18 13:01 ` Andrew Morton
2008-02-18 21:45 ` Neil Brown
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®