diff options
author | Sakari Ailus <[email protected]> | 2018-11-05 09:35:44 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <[email protected]> | 2018-11-06 07:07:40 -0500 |
commit | 92539d3eda2c090b382699bbb896d4b54e9bdece (patch) | |
tree | 587f4a98402040d908852b1113d2bc8b81f5f107 /fs/jbd2/commit.c | |
parent | b50b769bcbc24d68d95870d87354ec45fa0f07bb (diff) |
media: v4l: event: Add subscription to list before calling "add" operation
Patch ad608fbcf166 changed how events were subscribed to address an issue
elsewhere. As a side effect of that change, the "add" callback was called
before the event subscription was added to the list of subscribed events,
causing the first event queued by the add callback (and possibly other
events arriving soon afterwards) to be lost.
Fix this by adding the subscription to the list before calling the "add"
callback, and clean up afterwards if that fails.
Fixes: ad608fbcf166 ("media: v4l: event: Prevent freeing event subscriptions while accessed")
Reported-by: Dave Stevenson <[email protected]>
Signed-off-by: Sakari Ailus <[email protected]>
Tested-by: Dave Stevenson <[email protected]>
Reviewed-by: Hans Verkuil <[email protected]>
Tested-by: Hans Verkuil <[email protected]>
Cc: [email protected] (for 4.14 and up)
Signed-off-by: Mauro Carvalho Chehab <[email protected]>
Diffstat (limited to 'fs/jbd2/commit.c')
0 files changed, 0 insertions, 0 deletions