mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 10:41:38 -04:00
drm: Clean up pending events in the core
There's really no reason to not do so, instead of replicating this for every use-case and every driver. Now we can't just nuke the events, since that would still mean that all drm_event users would need to know when that has happened, since calling e.g. drm_send_event isn't allowed any more. Instead just unlink them from the file, and detect this case and handle it appropriately in all functions. v2: Adjust existing kerneldoc too. v3: Improve wording of the kerneldoc and split out vblank cleanup (Laurent). Cc: Alex Deucher <[email protected]> Cc: Laurent Pinchart <[email protected]> Acked-by: Daniel Stone <[email protected]> Reviewed-by: Alex Deucher <[email protected]> (v1) Reviewed-by: Laurent Pinchart <[email protected]> Signed-off-by: Daniel Vetter <[email protected]> Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
This commit is contained in:
parent
4020b220ed
commit
681047b486
2 changed files with 31 additions and 1 deletions
|
|
@ -283,6 +283,7 @@ struct drm_ioctl_desc {
|
|||
struct drm_pending_event {
|
||||
struct drm_event *event;
|
||||
struct list_head link;
|
||||
struct list_head pending_link;
|
||||
struct drm_file *file_priv;
|
||||
pid_t pid; /* pid of requester, no guarantee it's valid by the time
|
||||
we deliver the event, for tracing only */
|
||||
|
|
@ -346,6 +347,7 @@ struct drm_file {
|
|||
struct list_head blobs;
|
||||
|
||||
wait_queue_head_t event_wait;
|
||||
struct list_head pending_event_list;
|
||||
struct list_head event_list;
|
||||
int event_space;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue