Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 9ddc6b20 authored by Arun Menon's avatar Arun Menon
Browse files

msm: vidc: Fix race condition with v4l2 event handler



The v4l2 event handler struct should be initialized
before we add inst to the core->instances list.
Consider a case where there are few video sessions playing,
and a new video instance is opened. Before the new instance
is fully initialized, suppose there is a sys error from
firmware. In the response handler thread, driver will try
to send notifications to all the clients. Here it will
access the uninitialzed event handler struct of the recently
opened instance and crash. The fix is to ensure that the
instance is completely initialized before being added to the
core instance list.

Change-Id: Ic94a78b8948d904e357b94861e33a360409b082b
Signed-off-by: default avatarArun Menon <avmenon@codeaurora.org>
parent b06f2ad5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment