From 71d6f6e3ec3a64460eefc2e0f63019ef5bb561ca Mon Sep 17 00:00:00 2001
From: "Luis Claudio R. Goncalves" <lgoncalv@redhat.com>
Date: Thu, 8 Jun 2023 19:47:25 -0300
Subject: [PATCH 320/327] Revert "printk: declare
 printk_deferred_{enter,safe}() in include/linux/printk.h"

This reverts commit 32232bcd4e5300e678718d5c29da4dfa07ade01e.

The support for deferred printing was removed in v5.10-rc1-rt1 by commit
9153e3c5cb0c9 ("printk: remove deferred printing") because:

    Since printing occurs either atomically or from the printing
    kthread, there is no need for any deferring or tracking possible
    recursion paths. Remove all printk context tracking.

Fixes: 32232bcd4e530 ("printk: declare printk_deferred_{enter,safe}() in include/linux/printk.h")
Signed-off-by: Luis Claudio R. Goncalves <lgoncalv@redhat.com>
---
 include/linux/printk.h | 19 -------------------
 1 file changed, 19 deletions(-)

diff --git a/include/linux/printk.h b/include/linux/printk.h
index 83c7734e9802..7e4352467d83 100644
--- a/include/linux/printk.h
+++ b/include/linux/printk.h
@@ -609,23 +609,4 @@ static inline void print_hex_dump_debug(const char *prefix_str, int prefix_type,
 #define print_hex_dump_bytes(prefix_str, prefix_type, buf, len)	\
 	print_hex_dump_debug(prefix_str, prefix_type, 16, 1, buf, len, true)
 
-#ifdef CONFIG_PRINTK
-extern void __printk_safe_enter(void);
-extern void __printk_safe_exit(void);
-/*
- * The printk_deferred_enter/exit macros are available only as a hack for
- * some code paths that need to defer all printk console printing. Interrupts
- * must be disabled for the deferred duration.
- */
-#define printk_deferred_enter __printk_safe_enter
-#define printk_deferred_exit __printk_safe_exit
-#else
-static inline void printk_deferred_enter(void)
-{
-}
-static inline void printk_deferred_exit(void)
-{
-}
-#endif
-
 #endif
-- 
2.49.0

