imgv: Fix video bind page management
authorPauli Nieminen <pauli.nieminen@linux.intel.com>
Mon, 30 Jan 2012 17:17:27 +0000 (19:17 +0200)
committerMarkus Lehtonen <markus.lehtonen@linux.intel.com>
Tue, 3 Jul 2012 09:29:36 +0000 (12:29 +0300)
commit971dcdb6ef8258ffc362d835adac9ddbddbc3454
tree45a0027330500fec1508cfeafad924c0a931240c
parent19d768b0c6bd61904f91473bacef23b5948c3c1c
imgv: Fix video bind page management

Shared pages has to be reference count and free by kernel if userspace
fails to free them.

To have bind ioctl manage memory correctly use existing fiex pages
infrastructure to bind and unbind pages. Fixed pages already include ttm
backed functions to free pages correctly when application process
terminates.

Based on Robin Mathew's "Fix TTM Leaking on SIGKILL" patch.

Issue: Android-926
Signed-off-by: Pauli Nieminen <pauli.nieminen@linux.intel.com>
Acked-by: Imre Deak <imre.deak@intel.com>
Acked-by: Sean V Kelley <sean.v.kelley@intel.com>
Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
drivers/staging/mrst/imgv/psb_video_bind.c