summaryrefslogtreecommitdiffstats
path: root/debian/patches-rt/0035-printk-nbcon-Add-context-to-console_is_usable.patch
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-18 18:50:31 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-18 18:50:31 +0000
commitf7bf6055eb1e7ff603f0907b18ece35c72b05302 (patch)
tree13ac5b481056384a3ccc7979b86a42d208fcacdc /debian/patches-rt/0035-printk-nbcon-Add-context-to-console_is_usable.patch
parentMerging upstream version 6.8.9. (diff)
downloadlinux-f7bf6055eb1e7ff603f0907b18ece35c72b05302.tar.xz
linux-f7bf6055eb1e7ff603f0907b18ece35c72b05302.zip
Adding debian version 6.8.9-1.debian/6.8.9-1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r--debian/patches-rt/0035-printk-nbcon-Add-context-to-console_is_usable.patch (renamed from debian/patches-rt/0039-printk-nbcon-Add-context-to-console_is_usable.patch)38
1 files changed, 19 insertions, 19 deletions
diff --git a/debian/patches-rt/0039-printk-nbcon-Add-context-to-console_is_usable.patch b/debian/patches-rt/0035-printk-nbcon-Add-context-to-console_is_usable.patch
index 7702309536..bd434ec326 100644
--- a/debian/patches-rt/0039-printk-nbcon-Add-context-to-console_is_usable.patch
+++ b/debian/patches-rt/0035-printk-nbcon-Add-context-to-console_is_usable.patch
@@ -1,7 +1,7 @@
From: John Ogness <john.ogness@linutronix.de>
Date: Tue, 26 Sep 2023 14:43:30 +0000
-Subject: [PATCH 39/50] printk: nbcon: Add context to console_is_usable()
-Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/6.7/older/patches-6.7-rt6.tar.xz
+Subject: [PATCH 35/48] printk: nbcon: Add context to console_is_usable()
+Origin: https://www.kernel.org/pub/linux/kernel/projects/rt/6.8/older/patches-6.8.2-rt11.tar.xz
The nbcon consoles have two callbacks to be used for different
contexts. In order to determine if an nbcon console is usable,
@@ -20,7 +20,7 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
--- a/kernel/printk/internal.h
+++ b/kernel/printk/internal.h
-@@ -100,7 +100,7 @@ void nbcon_kthread_create(struct console
+@@ -98,7 +98,7 @@ void nbcon_kthread_create(struct console
* which can also play a role in deciding if @con can be used to print
* records.
*/
@@ -29,26 +29,26 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
{
if (!(flags & CON_ENABLED))
return false;
-@@ -109,10 +109,13 @@ static inline bool console_is_usable(str
+@@ -107,10 +107,13 @@ static inline bool console_is_usable(str
return false;
if (flags & CON_NBCON) {
- if (!con->write_atomic)
- return false;
-- if (!con->write_thread || !con->kthread)
+- if (!con->write_thread)
- return false;
+ if (use_atomic) {
+ if (!con->write_atomic)
+ return false;
+ } else {
-+ if (!con->write_thread || !con->kthread)
++ if (!con->write_thread)
+ return false;
+ }
} else {
if (!con->write)
return false;
-@@ -178,7 +181,8 @@ static inline void nbcon_atomic_flush_al
- static inline bool nbcon_atomic_emit_next_record(struct console *con, bool *handover,
+@@ -175,7 +178,8 @@ static inline void nbcon_atomic_flush_pe
+ static inline bool nbcon_legacy_emit_next_record(struct console *con, bool *handover,
int cookie) { return false; }
-static inline bool console_is_usable(struct console *con, short flags) { return false; }
@@ -59,25 +59,25 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
--- a/kernel/printk/nbcon.c
+++ b/kernel/printk/nbcon.c
-@@ -963,7 +963,7 @@ static bool nbcon_kthread_should_wakeup(
-
+@@ -968,7 +968,7 @@ static bool nbcon_kthread_should_wakeup(
cookie = console_srcu_read_lock();
+
flags = console_srcu_read_flags(con);
-- is_usable = console_is_usable(con, flags);
-+ is_usable = console_is_usable(con, flags, false);
- console_srcu_read_unlock(cookie);
+- if (console_is_usable(con, flags)) {
++ if (console_is_usable(con, flags, false)) {
+ /* Bring the sequence in @ctxt up to date */
+ ctxt->seq = nbcon_seq_read(con);
- if (!is_usable)
-@@ -1022,7 +1022,7 @@ static int nbcon_kthread_func(void *__co
+@@ -1026,7 +1026,7 @@ static int nbcon_kthread_func(void *__co
con_flags = console_srcu_read_flags(con);
- if (console_is_usable(con, con_flags)) {
+ if (console_is_usable(con, con_flags, false)) {
- con->driver_enter(con, &flags);
+ con->device_lock(con, &flags);
/*
-@@ -1203,7 +1203,7 @@ static void __nbcon_atomic_flush_all(u64
+@@ -1246,7 +1246,7 @@ static void __nbcon_atomic_flush_pending
if (!(flags & CON_NBCON))
continue;
@@ -88,7 +88,7 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
if (nbcon_seq_read(con) >= stop_seq)
--- a/kernel/printk/printk.c
+++ b/kernel/printk/printk.c
-@@ -3047,7 +3047,7 @@ static bool console_flush_all(bool do_co
+@@ -3056,7 +3056,7 @@ static bool console_flush_all(bool do_co
if ((flags & CON_NBCON) && con->kthread)
continue;
@@ -97,7 +97,7 @@ Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
continue;
any_usable = true;
-@@ -3952,8 +3952,10 @@ static bool __pr_flush(struct console *c
+@@ -3991,8 +3991,10 @@ static bool __pr_flush(struct console *c
* that they make forward progress, so only increment
* @diff for usable consoles.
*/