diff options
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; }; |