diff options
author | Eric W. Biederman <ebiederm@xmission.com> | 2009-11-11 22:32:48 -0500 |
---|---|---|
committer | Eric W. Biederman <ebiederm@xmission.com> | 2009-11-11 22:35:52 -0500 |
commit | 2fb10732c3b3c9671b1a391996ce7e551876c25e (patch) | |
tree | 84944564aaefa5c702c79dc20ccc9ecec34dc0a8 | |
parent | 2315ffa0a9f789c588c7139effa7404a387d8685 (diff) |
sysctl: Warn about all uses of sys_sysctl.
Now that the glibc pthread implemenation no longers uses sysctl() users
of sysctl are as rare as hen's teeth. So remove the glibc exception
from the warning, and use the standard printk_ratelimit instead of
rolling our own.
Signed-off-by: Eric W. Biederman <ebiederm@xmission.com>
-rw-r--r-- | kernel/sysctl_binary.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/kernel/sysctl_binary.c b/kernel/sysctl_binary.c index 471438bbece6..bf0a4b06782a 100644 --- a/kernel/sysctl_binary.c +++ b/kernel/sysctl_binary.c | |||
@@ -1393,15 +1393,9 @@ static ssize_t binary_sysctl(const int *name, int nlen, | |||
1393 | 1393 | ||
1394 | static void deprecated_sysctl_warning(const int *name, int nlen) | 1394 | static void deprecated_sysctl_warning(const int *name, int nlen) |
1395 | { | 1395 | { |
1396 | static int msg_count; | ||
1397 | int i; | 1396 | int i; |
1398 | 1397 | ||
1399 | /* Ignore accesses to kernel.version */ | 1398 | if (printk_ratelimit()) { |
1400 | if ((nlen == 2) && (name[0] == CTL_KERN) && (name[1] == KERN_VERSION)) | ||
1401 | return; | ||
1402 | |||
1403 | if (msg_count < 5) { | ||
1404 | msg_count++; | ||
1405 | printk(KERN_INFO | 1399 | printk(KERN_INFO |
1406 | "warning: process `%s' used the deprecated sysctl " | 1400 | "warning: process `%s' used the deprecated sysctl " |
1407 | "system call with ", current->comm); | 1401 | "system call with ", current->comm); |