summaryrefslogtreecommitdiffstats
path: root/debian/patches-rt/0097-printk-remove-safe-buffers.patch
diff options
context:
space:
mode:
Diffstat (limited to 'debian/patches-rt/0097-printk-remove-safe-buffers.patch')
-rw-r--r--debian/patches-rt/0097-printk-remove-safe-buffers.patch52
1 files changed, 26 insertions, 26 deletions
diff --git a/debian/patches-rt/0097-printk-remove-safe-buffers.patch b/debian/patches-rt/0097-printk-remove-safe-buffers.patch
index df3318972..09993c97c 100644
--- a/debian/patches-rt/0097-printk-remove-safe-buffers.patch
+++ b/debian/patches-rt/0097-printk-remove-safe-buffers.patch
@@ -1,8 +1,8 @@
-From c0ee407b7db3b7ac5c24337a9d365a35450c233b Mon Sep 17 00:00:00 2001
+From 08536603e3b6037a7d2e2d52bce1dca2628a14ac Mon Sep 17 00:00:00 2001
From: John Ogness <john.ogness@linutronix.de>
Date: Mon, 30 Nov 2020 01:42:00 +0106
Subject: [PATCH 097/323] printk: remove safe buffers
-Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/5.10/older/patches-5.10.204-rt100.tar.xz
+Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/5.10/older/patches-5.10.215-rt107.tar.xz
With @logbuf_lock removed, the high level printk functions for
storing messages are lockless. Messages can be stored from any
@@ -27,7 +27,7 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
9 files changed, 17 insertions(+), 425 deletions(-)
diff --git a/arch/powerpc/kernel/traps.c b/arch/powerpc/kernel/traps.c
-index 5e5a2448ae79..d39a4a6b4ddf 100644
+index b0e87dce2b9a0..5dfe1aea62054 100644
--- a/arch/powerpc/kernel/traps.c
+++ b/arch/powerpc/kernel/traps.c
@@ -170,7 +170,6 @@ extern void panic_flush_kmsg_start(void)
@@ -39,7 +39,7 @@ index 5e5a2448ae79..d39a4a6b4ddf 100644
bust_spinlocks(0);
debug_locks_off();
diff --git a/arch/powerpc/kernel/watchdog.c b/arch/powerpc/kernel/watchdog.c
-index 75b2a6c4db5a..db40e20d0c54 100644
+index 75b2a6c4db5a5..db40e20d0c54a 100644
--- a/arch/powerpc/kernel/watchdog.c
+++ b/arch/powerpc/kernel/watchdog.c
@@ -185,11 +185,6 @@ static void watchdog_smp_panic(int cpu, u64 tb)
@@ -55,7 +55,7 @@ index 75b2a6c4db5a..db40e20d0c54 100644
trigger_allbutself_cpu_backtrace();
diff --git a/include/linux/printk.h b/include/linux/printk.h
-index 344f6da3d4c3..c6bb48f0134c 100644
+index 344f6da3d4c36..c6bb48f0134c0 100644
--- a/include/linux/printk.h
+++ b/include/linux/printk.h
@@ -207,8 +207,6 @@ __printf(1, 2) void dump_stack_set_arch_desc(const char *fmt, ...);
@@ -83,7 +83,7 @@ index 344f6da3d4c3..c6bb48f0134c 100644
extern int kptr_restrict;
diff --git a/kernel/kexec_core.c b/kernel/kexec_core.c
-index 3a37fc62dc95..78a1fd9c3c8a 100644
+index 3a37fc62dc95f..78a1fd9c3c8a7 100644
--- a/kernel/kexec_core.c
+++ b/kernel/kexec_core.c
@@ -978,7 +978,6 @@ void crash_kexec(struct pt_regs *regs)
@@ -95,7 +95,7 @@ index 3a37fc62dc95..78a1fd9c3c8a 100644
/*
diff --git a/kernel/panic.c b/kernel/panic.c
-index bc39e2b27d31..7965f1e31224 100644
+index 30d8da0d43d8f..7fc35d3675e1b 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -324,7 +324,6 @@ void panic(const char *fmt, ...)
@@ -116,7 +116,7 @@ index bc39e2b27d31..7965f1e31224 100644
/*
diff --git a/kernel/printk/internal.h b/kernel/printk/internal.h
-index e7acc2888c8e..e108b2ece8c7 100644
+index e7acc2888c8e1..e108b2ece8c70 100644
--- a/kernel/printk/internal.h
+++ b/kernel/printk/internal.h
@@ -23,7 +23,6 @@ __printf(1, 0) int vprintk_func(const char *fmt, va_list args);
@@ -135,7 +135,7 @@ index e7acc2888c8e..e108b2ece8c7 100644
static inline bool printk_percpu_data_ready(void) { return false; }
#endif /* CONFIG_PRINTK */
diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c
-index 31a2b7a116a7..90a4cf4c23a4 100644
+index 08a49c8e7239e..150b0b90ceb44 100644
--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
@@ -735,27 +735,22 @@ static ssize_t devkmsg_read(struct file *file, char __user *buf,
@@ -341,7 +341,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
break;
/* Size of the log buffer */
case SYSLOG_ACTION_SIZE_BUFFER:
-@@ -2210,7 +2179,6 @@ asmlinkage int vprintk_emit(int facility, int level,
+@@ -2216,7 +2185,6 @@ asmlinkage int vprintk_emit(int facility, int level,
{
int printed_len;
bool in_sched = false;
@@ -349,7 +349,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
/* Suppress unimportant messages after panic happens */
if (unlikely(suppress_printk))
-@@ -2224,9 +2192,7 @@ asmlinkage int vprintk_emit(int facility, int level,
+@@ -2230,9 +2198,7 @@ asmlinkage int vprintk_emit(int facility, int level,
boot_delay_msec(level);
printk_delay();
@@ -359,7 +359,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
/* If called from the scheduler, we can not call up(). */
if (!in_sched) {
-@@ -2618,7 +2584,6 @@ void console_unlock(void)
+@@ -2624,7 +2590,6 @@ void console_unlock(void)
{
static char ext_text[CONSOLE_EXT_LOG_MAX];
static char text[CONSOLE_LOG_MAX];
@@ -367,7 +367,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
bool do_cond_resched, retry;
struct printk_info info;
struct printk_record r;
-@@ -2663,7 +2628,6 @@ void console_unlock(void)
+@@ -2669,7 +2634,6 @@ void console_unlock(void)
size_t ext_len = 0;
size_t len;
@@ -375,7 +375,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
skip:
if (!prb_read_valid(prb, console_seq, &r))
break;
-@@ -2720,12 +2684,8 @@ void console_unlock(void)
+@@ -2726,12 +2690,8 @@ void console_unlock(void)
call_console_drivers(ext_text, ext_len, text, len);
start_critical_timings();
@@ -389,7 +389,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
if (do_cond_resched)
cond_resched();
-@@ -2742,8 +2702,6 @@ void console_unlock(void)
+@@ -2748,8 +2708,6 @@ void console_unlock(void)
* flush, no worries.
*/
retry = prb_read_valid(prb, console_seq, NULL);
@@ -398,7 +398,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
if (retry && console_trylock())
goto again;
}
-@@ -2805,13 +2763,8 @@ void console_flush_on_panic(enum con_flush_mode mode)
+@@ -2811,13 +2769,8 @@ void console_flush_on_panic(enum con_flush_mode mode)
console_trylock();
console_may_schedule = 0;
@@ -413,7 +413,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
console_unlock();
}
-@@ -3469,11 +3422,9 @@ bool kmsg_dump_get_line(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3498,11 +3451,9 @@ bool kmsg_dump_get_line(struct kmsg_dumper_iter *iter, bool syslog,
struct printk_info info;
unsigned int line_count;
struct printk_record r;
@@ -425,7 +425,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
prb_rec_init_rd(&r, &info, line, size);
if (!iter->active)
-@@ -3497,7 +3448,6 @@ bool kmsg_dump_get_line(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3526,7 +3477,6 @@ bool kmsg_dump_get_line(struct kmsg_dumper_iter *iter, bool syslog,
iter->cur_seq = r.info->seq + 1;
ret = true;
out:
@@ -433,7 +433,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
if (len)
*len = l;
return ret;
-@@ -3528,7 +3478,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3557,7 +3507,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
{
struct printk_info info;
struct printk_record r;
@@ -441,7 +441,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
u64 seq;
u64 next_seq;
size_t len = 0;
-@@ -3538,7 +3487,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3567,7 +3516,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
if (!iter->active || !buf || !size)
goto out;
@@ -449,7 +449,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
if (prb_read_valid_info(prb, iter->cur_seq, &info, NULL)) {
if (info.seq != iter->cur_seq) {
/* messages are gone, move to first available one */
-@@ -3547,10 +3495,8 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3576,10 +3524,8 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
}
/* last entry */
@@ -461,7 +461,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
/*
* Find first record that fits, including all following records,
-@@ -3582,7 +3528,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
+@@ -3611,7 +3557,6 @@ bool kmsg_dump_get_buffer(struct kmsg_dumper_iter *iter, bool syslog,
iter->next_seq = next_seq;
ret = true;
@@ -469,7 +469,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
out:
if (len_out)
*len_out = len;
-@@ -3600,12 +3545,8 @@ EXPORT_SYMBOL_GPL(kmsg_dump_get_buffer);
+@@ -3629,12 +3574,8 @@ EXPORT_SYMBOL_GPL(kmsg_dump_get_buffer);
*/
void kmsg_dump_rewind(struct kmsg_dumper_iter *iter)
{
@@ -483,7 +483,7 @@ index 31a2b7a116a7..90a4cf4c23a4 100644
EXPORT_SYMBOL_GPL(kmsg_dump_rewind);
diff --git a/kernel/printk/printk_safe.c b/kernel/printk/printk_safe.c
-index 7df8a88d4115..c23b127a6545 100644
+index 7df8a88d4115e..c23b127a65459 100644
--- a/kernel/printk/printk_safe.c
+++ b/kernel/printk/printk_safe.c
@@ -15,282 +15,9 @@
@@ -856,7 +856,7 @@ index 7df8a88d4115..c23b127a6545 100644
- printk_safe_flush();
-}
diff --git a/lib/nmi_backtrace.c b/lib/nmi_backtrace.c
-index 8abe1870dba4..b09a490f5f70 100644
+index 8abe1870dba4e..b09a490f5f706 100644
--- a/lib/nmi_backtrace.c
+++ b/lib/nmi_backtrace.c
@@ -75,12 +75,6 @@ void nmi_trigger_cpumask_backtrace(const cpumask_t *mask,
@@ -873,5 +873,5 @@ index 8abe1870dba4..b09a490f5f70 100644
put_cpu();
}
--
-2.43.0
+2.44.0