]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
kmsg-honor-dmesg_restrict-sysctl-on-dev-kmsg-fix
authorAndrew Morton <akpm@linux-foundation.org>
Thu, 9 May 2013 23:57:06 +0000 (09:57 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 21 May 2013 04:17:35 +0000 (14:17 +1000)
use pr_warn_once()

Cc: Josh Boyer <jwboyer@redhat.com>
Cc: Kees Cook <keescook@chromium.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
kernel/printk.c

index 84e01c9ba2bab457c6df045bbaab04362b072150..b8c348a6b797c178bbd574a4ff6f1ce67ca1687c 100644 (file)
@@ -398,9 +398,9 @@ static int check_syslog_permissions(int type, bool from_file)
                 * a warning.
                 */
                if (capable(CAP_SYS_ADMIN)) {
-                       printk_once(KERN_WARNING "%s (%d): "
-                                "Attempt to access syslog with CAP_SYS_ADMIN "
-                                "but no CAP_SYSLOG (deprecated).\n",
+                       pr_warn_once("%s (%d): Attempt to access syslog with "
+                                    "CAP_SYS_ADMIN but no CAP_SYSLOG "
+                                    "(deprecated).\n",
                                 current->comm, task_pid_nr(current));
                        return 0;
                }