Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

drm/vblank: Warn when silently cancelling vblank works

Silently cancelling vblank works is a bit rude, especially
if said works do any resource management (eg. free memory).
WARN if we ever hit this.

TODO: Maybe drm_crtc_vblank_off() should wait for any
pending work to reach its target vblank before actually
doing anything drastic?

Cc: Lyude Paul <lyude@redhat.com>
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230920140339.28322-2-ville.syrjala@linux.intel.com
Reviewed-by: Lyude Paul <lyude@redhat.com>

+3
+3
drivers/gpu/drm/drm_vblank_work.c
··· 73 73 74 74 assert_spin_locked(&vblank->dev->event_lock); 75 75 76 + drm_WARN_ONCE(vblank->dev, !list_empty(&vblank->pending_work), 77 + "Cancelling pending vblank works!\n"); 78 + 76 79 list_for_each_entry_safe(work, next, &vblank->pending_work, node) { 77 80 list_del_init(&work->node); 78 81 drm_vblank_put(vblank->dev, vblank->pipe);