* [PATCH] printk: Fix unused printk_time compile warning when !CONFIG_PRINTK
@ 2017-09-26 15:59 Prarit Bhargava
0 siblings, 0 replies; only message in thread
From: Prarit Bhargava @ 2017-09-26 15:59 UTC (permalink / raw)
To: linux-kernel; +Cc: Prarit Bhargava, Thomas Gleixner
Patch is against -tip and tglx requested a delta patch.
P.
---8<---
When !CONFIG_PRINTK the compile warns with
CC kernel/printk/printk.o
kernel/printk/printk.c:1983:12: warning: ‘printk_time’ defined but not
used [-Wunused-variable]
static int printk_time;
Remove the printk_time declaration for !CONFIG_PRINTK.
Reported-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
---
kernel/printk/printk.c | 2 --
1 file changed, 2 deletions(-)
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c
index 5e0bf2ef02f7..fe94246fa073 100644
--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
@@ -1979,8 +1979,6 @@ static void call_console_drivers(const char *ext_text, size_t ext_len,
static size_t msg_print_text(const struct printk_log *msg,
bool syslog, char *buf, size_t size) { return 0; }
static bool suppress_message_printing(int level) { return false; }
-
-static int printk_time;
#endif /* CONFIG_PRINTK */
#ifdef CONFIG_EARLY_PRINTK
--
1.8.5.5
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2017-09-26 15:59 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-26 15:59 [PATCH] printk: Fix unused printk_time compile warning when !CONFIG_PRINTK Prarit Bhargava
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Powered by JetHome