mm-video-v4l2: Protect buffer lifecycle with lock

IL Client may choose to free the buffer which might
be in-use by IL component.This may lead to use-after
free situation.
Protect buffer lifecycle with a lock to ensure that
IL component operates on a buffer which exists.

Fixes bug 62452543
 Security Vulnerability - Heap use after free in libOmxVenc

CRs-Fixed: 2062772
Change-Id: I0fdb4051c94044e032c257febbe2ba1c7e4d6c7e
1 file changed