msm: vidc: Do not unmap same buffer twice
The registeredbufs list may include nodes with
buffers which have the same fd but different offsets.
These buffers would be mapped once initally when they
are added to the list. Make sure to unmap them only
once by checking if the mapped field is set to true.
Without this change, the same buffer would get unmapped
twice and that would result in a device crash because
of NULL pointer access during unmap.
Change-Id: I7b77d832549b6e37a2ecfa36b563eebe9115a0fd
Signed-off-by:
Arun Menon <avmenon@codeaurora.org>
Loading
Please register or sign in to comment