diff options
author | Petr Mladek <pmladek@suse.com> | 2022-05-23 10:55:39 +0200 |
---|---|---|
committer | Petr Mladek <pmladek@suse.com> | 2022-05-23 10:55:39 +0200 |
commit | 1c6fd59943a630f087b4b3089aefdcb0bf43cca0 (patch) | |
tree | 4806aa6762bde2835b2be5f2ee4c8be40536e910 /include/linux/console.h | |
parent | a5c7a39f508ae1fd3288493b96dd26079bae41bf (diff) | |
parent | 701850dc0c31bfadf75a0a74af7d2c97859945ec (diff) | |
download | linux-1c6fd59943a630f087b4b3089aefdcb0bf43cca0.tar.gz linux-1c6fd59943a630f087b4b3089aefdcb0bf43cca0.tar.bz2 linux-1c6fd59943a630f087b4b3089aefdcb0bf43cca0.zip |
Merge branch 'rework/kthreads' into for-linus
Diffstat (limited to 'include/linux/console.h')
-rw-r--r-- | include/linux/console.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/include/linux/console.h b/include/linux/console.h index 7cd758a4f44e..143653090c48 100644 --- a/include/linux/console.h +++ b/include/linux/console.h @@ -16,6 +16,7 @@ #include <linux/atomic.h> #include <linux/types.h> +#include <linux/mutex.h> struct vc_data; struct console_font_op; @@ -151,6 +152,24 @@ struct console { int cflag; uint ispeed; uint ospeed; + u64 seq; + unsigned long dropped; + struct task_struct *thread; + bool blocked; + + /* + * The per-console lock is used by printing kthreads to synchronize + * this console with callers of console_lock(). This is necessary in + * order to allow printing kthreads to run in parallel to each other, + * while each safely accessing the @blocked field and synchronizing + * against direct printing via console_lock/console_unlock. + * + * Note: For synchronizing against direct printing via + * console_trylock/console_unlock, see the static global + * variable @console_kthreads_active. + */ + struct mutex lock; + void *data; struct console *next; }; |