Skip to content

Commit

Permalink
smaps: only define clear_refs for CONFIG_MMU
Browse files Browse the repository at this point in the history
/proc/pid/clear_refs is only defined in the CONFIG_MMU case, so make sure we
don't have any references to clear_refs_smap() in generic procfs code.

Signed-off-by: David Rientjes <rientjes@google.com>
Signed-off-by: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
David Rientjes authored and Linus Torvalds committed May 9, 2007
1 parent 7e81ab9 commit 4b8df89
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fs/proc/base.c
Original file line number Diff line number Diff line change
Expand Up @@ -708,6 +708,7 @@ static const struct file_operations proc_oom_adjust_operations = {
.write = oom_adjust_write,
};

#ifdef CONFIG_MMU
static ssize_t clear_refs_write(struct file *file, const char __user *buf,
size_t count, loff_t *ppos)
{
Expand Down Expand Up @@ -741,6 +742,7 @@ static ssize_t clear_refs_write(struct file *file, const char __user *buf,
static struct file_operations proc_clear_refs_operations = {
.write = clear_refs_write,
};
#endif

#ifdef CONFIG_AUDITSYSCALL
#define TMPBUFLEN 21
Expand Down

0 comments on commit 4b8df89

Please sign in to comment.