The patch titled printk_ratelimit functions should use CONFIG_PRINTK has been removed from the -mm tree. Its filename was printk_ratelimit-functions-should-use-config_printk.patch This patch was dropped because either git-sched or git-x86 wrecked it The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: printk_ratelimit functions should use CONFIG_PRINTK From: Joe Perches <joe@xxxxxxxxxxx> Makes an embedded image a bit smaller Signed-off-by: Joe Perches <joe@xxxxxxxxxxx> Acked-by: Matt Mackall <mpm@xxxxxxxxxxx> Cc: Ingo Molnar <mingo@xxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- include/linux/kernel.h | 20 +++++++++++++++----- kernel/printk.c | 2 ++ kernel/sysctl.c | 20 ++++++++++---------- 3 files changed, 27 insertions(+), 15 deletions(-) diff -puN include/linux/kernel.h~printk_ratelimit-functions-should-use-config_printk include/linux/kernel.h --- a/include/linux/kernel.h~printk_ratelimit-functions-should-use-config_printk +++ a/include/linux/kernel.h @@ -182,6 +182,13 @@ asmlinkage int printk(const char * fmt, extern int log_buf_get_len(void); extern int log_buf_read(int idx); extern int log_buf_copy(char *dest, int idx, int len); + +extern int printk_ratelimit_jiffies; +extern int printk_ratelimit_burst; +extern int printk_ratelimit(void); +extern int __printk_ratelimit(int ratelimit_jiffies, int ratelimit_burst); +extern bool printk_timed_ratelimit(unsigned long *caller_jiffies, + unsigned int interval_msec); #else static inline int vprintk(const char *s, va_list args) __attribute__ ((format (printf, 1, 0))); @@ -192,15 +199,18 @@ static inline int __cold printk(const ch static inline int log_buf_get_len(void) { return 0; } static inline int log_buf_read(int idx) { return 0; } static inline int log_buf_copy(char *dest, int idx, int len) { return 0; } + +static inline int printk_ratelimit(void) { return 0; } +static inline int __printk_ratelimit(int ratelimit_jiffies, \ + int ratelimit_burst) { return 0; } +static inline bool printk_timed_ratelimit(unsigned long *caller_jiffies, \ + unsigned int interval_msec) \ + { return false; } + #endif unsigned long int_sqrt(unsigned long); -extern int printk_ratelimit(void); -extern int __printk_ratelimit(int ratelimit_jiffies, int ratelimit_burst); -extern bool printk_timed_ratelimit(unsigned long *caller_jiffies, - unsigned int interval_msec); - static inline void console_silent(void) { console_loglevel = 0; diff -puN kernel/printk.c~printk_ratelimit-functions-should-use-config_printk kernel/printk.c --- a/kernel/printk.c~printk_ratelimit-functions-should-use-config_printk +++ a/kernel/printk.c @@ -1258,6 +1258,7 @@ void tty_write_message(struct tty_struct return; } +#if defined CONFIG_PRINTK /* * printk rate limiting, lifted from the networking subsystem. * @@ -1327,3 +1328,4 @@ bool printk_timed_ratelimit(unsigned lon return false; } EXPORT_SYMBOL(printk_timed_ratelimit); +#endif diff -puN kernel/sysctl.c~printk_ratelimit-functions-should-use-config_printk kernel/sysctl.c --- a/kernel/sysctl.c~printk_ratelimit-functions-should-use-config_printk +++ a/kernel/sysctl.c @@ -73,8 +73,6 @@ extern int suid_dumpable; extern char core_pattern[]; extern int pid_max; extern int min_free_kbytes; -extern int printk_ratelimit_jiffies; -extern int printk_ratelimit_burst; extern int pid_max_min, pid_max_max; extern int sysctl_drop_caches; extern int percpu_pagelist_fraction; @@ -475,14 +473,6 @@ static struct ctl_table kern_table[] = { .mode = 0644, .proc_handler = &proc_dointvec, }, - { - .ctl_name = KERN_PRINTK, - .procname = "printk", - .data = &console_loglevel, - .maxlen = 4*sizeof(int), - .mode = 0644, - .proc_handler = &proc_dointvec, - }, #ifdef CONFIG_KMOD { .ctl_name = KERN_MODPROBE, @@ -629,6 +619,15 @@ static struct ctl_table kern_table[] = { .mode = 0644, .proc_handler = &proc_dointvec, }, +#if defined CONFIG_PRINTK + { + .ctl_name = KERN_PRINTK, + .procname = "printk", + .data = &console_loglevel, + .maxlen = 4*sizeof(int), + .mode = 0644, + .proc_handler = &proc_dointvec, + }, { .ctl_name = KERN_PRINTK_RATELIMIT, .procname = "printk_ratelimit", @@ -646,6 +645,7 @@ static struct ctl_table kern_table[] = { .mode = 0644, .proc_handler = &proc_dointvec, }, +#endif { .ctl_name = KERN_NGROUPS_MAX, .procname = "ngroups_max", _ Patches currently in -mm which might be from joe@xxxxxxxxxxx are git-alsa.patch git-cpufreq.patch git-powerpc.patch git-dvb.patch git-hwmon.patch git-ieee1394.patch git-infiniband.patch git-jfs.patch git-kvm.patch git-net.patch git-netdev-all.patch git-selinux.patch git-s390.patch git-sh.patch git-unionfs.patch git-x86.patch uml-add-missing-space.patch uml-style-fixes-in-arch-um-kernel.patch printk_ratelimit-functions-should-use-config_printk.patch maintainers-remove-adam-fritzler-update-his-email-address-in-other-sources.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html