In case of legacy cursor update, the cursor VMA needs to be unpinned only after vblank. This exceeds the lifetime of the whole atomic commit. Any trick I attempted to keep the atomic commit alive didn't work, as drm_atomic_helper_setup_commit() force throttles on any old commit that wasn't cleaned up. The only option remaining is to remove the plane from the atomic commit, and use the same path as the legacy cursor update to clean the state after vblank. Changes since previous version: - Call the memset for plane state immediately when scheduling vblank, this prevents a use-after-free in cursor cleanup. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com> Reviewed-by: Uma Shankar <uma.shankar@intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240522053341.137592-4-maarten.lankhorst@linux.intel.com
20 lines
381 B
C
20 lines
381 B
C
/* SPDX-License-Identifier: MIT */
|
|
/*
|
|
* Copyright © 2020 Intel Corporation
|
|
*/
|
|
|
|
#ifndef _INTEL_CURSOR_H_
|
|
#define _INTEL_CURSOR_H_
|
|
|
|
enum pipe;
|
|
struct drm_i915_private;
|
|
struct intel_plane;
|
|
struct kthread_work;
|
|
|
|
struct intel_plane *
|
|
intel_cursor_plane_create(struct drm_i915_private *dev_priv,
|
|
enum pipe pipe);
|
|
|
|
void intel_cursor_unpin_work(struct kthread_work *base);
|
|
|
|
#endif
|