media: tegra: nvavp: Fix heap overflow
authorSomasundaram S <somasundaram@nvidia.com>
Thu, 10 Mar 2016 12:03:11 +0000 (17:03 +0530)
committerManish Tuteja <mtuteja@nvidia.com>
Mon, 14 Mar 2016 06:42:06 +0000 (23:42 -0700)
commit8eb452ecf6e1ca5bdfb49b840cb025661a100be5
tree8106027339ca8388fe5b10e0abb0c3a6f7b6dce6
parentc8555017337149fc101db58f64b73dd4f8d65e0b
media: tegra: nvavp: Fix heap overflow

Bug 1739930

Increase NVAVP_MAX_RELOCATION_COUNT to max. possible value
and add check to return error if num_relocs in
nvavp_pushbuffer_submit_ioctl exceeds
NVAVP_MAX_RELOCATION_COUNT

Change-Id: Ief36cedd692aa53135fc6a0039b19f18609259dd
Signed-off-by: Somasundaram S <somasundaram@nvidia.com>
Reviewed-on: http://git-master/r/1028913
(cherry-picked from commit <TODO>)
Reviewed-on: http://git-master/r/1029636
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Manish Tuteja <mtuteja@nvidia.com>
Tested-by: Manish Tuteja <mtuteja@nvidia.com>
drivers/media/platform/tegra/nvavp/nvavp_dev.c
include/linux/tegra_nvavp.h