aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/cdx/controller/cdx_controller.c
diff options
context:
space:
mode:
authorThomas Gleixner <[email protected]>2023-09-16 19:20:04 +0000
committerPetr Mladek <[email protected]>2023-09-18 15:03:45 +0000
commit4b08d9e24f50163a8bda0a702b45b06bf841d792 (patch)
treee9fa83236e90d6ed307f62ca6c1ec54ace0f8ca8 /drivers/cdx/controller/cdx_controller.c
parentprintk: nbcon: Add buffer management (diff)
downloadkernel-4b08d9e24f50163a8bda0a702b45b06bf841d792.tar.gz
kernel-4b08d9e24f50163a8bda0a702b45b06bf841d792.zip
printk: nbcon: Add ownership state functions
Provide functions that are related to the safe handover mechanism and allow console drivers to dynamically specify unsafe regions: - nbcon_context_can_proceed() Invoked by a console owner to check whether a handover request is pending or whether the console has been taken over by another context. If a handover request is pending, this function will also perform the handover, thus cancelling its own ownership. - nbcon_context_enter_unsafe()/nbcon_context_exit_unsafe() Invoked by a console owner to denote that the driver is about to enter or leave a critical region where a take over is unsafe. The exit variant is the point where the current owner releases the lock for a higher priority context which asked for the friendly handover. The unsafe state is stored in the console state and allows a new context to make informed decisions whether to attempt a takeover of such a console. The unsafe state is also available to the driver so that it can make informed decisions about the required actions and possibly take a special emergency path. Co-developed-by: John Ogness <[email protected]> Signed-off-by: John Ogness <[email protected]> Signed-off-by: Thomas Gleixner (Intel) <[email protected]> Reviewed-by: Petr Mladek <[email protected]> Signed-off-by: Petr Mladek <[email protected]> Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'drivers/cdx/controller/cdx_controller.c')
0 files changed, 0 insertions, 0 deletions