Lines Matching +full:hardware +full:- +full:protected

1 /* SPDX-License-Identifier: GPL-2.0 or MIT */
13 #include <linux/iosys-map.h>
19 * struct drm_scanout_buffer - DRM scanout buffer
37 * sent to the display hardware. Tearing is not an issue for the panic
68 * drm_panic_trylock - try to enter the panic printing critical section
78 * - Anything protected by drm_panic_lock() and drm_panic_unlock() pairs is safe
81 * - Furthermore the panic printing code only registers in drm_dev_unregister()
90 * - It is safe to deference the drm_plane.state pointer.
92 * - Anything in struct drm_plane_state or the driver's subclass thereof which
97 * - Anything set up by &drm_plane_helper_funcs.fb_prepare and cleaned up
104 * - Importantly, software and hardware state set up by
108 * Drivers must not make any assumptions about the actual state of the hardware,
109 * unless they explicitly protected these hardware access with drm_panic_lock()
116 raw_spin_trylock_irqsave(&(dev)->mode_config.panic_lock, flags)
119 * drm_panic_lock - protect panic printing relevant state
123 * This function must be called to protect software and hardware state that the
124 * panic printing code must be able to rely on. The protected sections must be
128 * - Access to peek/poke or other similar registers, if that is the way the
131 * - Updates to pointers like &drm_plane.state, allowing the panic handler to
134 * - An state that isn't invariant and that the driver must be able to access
139 raw_spin_lock_irqsave(&(dev)->mode_config.panic_lock, flags)
142 * drm_panic_unlock - end of the panic printing critical section
150 raw_spin_unlock_irqrestore(&(dev)->mode_config.panic_lock, flags)