diff options
author | HeynChul Jun <hcjun@nexell.co.kr> | 2019-04-08 14:04:09 +0900 |
---|---|---|
committer | Seung-Woo Kim <sw0312.kim@samsung.com> | 2020-07-09 18:16:15 +0900 |
commit | b4ab75e76a8cb82ba960c9e918e56e523f5b8bfd (patch) | |
tree | c3fa06af1a819e624bf3bc76ee701b92db16167f | |
parent | 01a9e1b15be53b18fdaa6b0fd4b068b825f8cdd7 (diff) | |
download | linux-artik7-b4ab75e76a8cb82ba960c9e918e56e523f5b8bfd.tar.gz linux-artik7-b4ab75e76a8cb82ba960c9e918e56e523f5b8bfd.tar.bz2 linux-artik7-b4ab75e76a8cb82ba960c9e918e56e523f5b8bfd.zip |
media: nx-vpu: bug fix memory corruption
This patch fixes memory corruption.
The MAX_REG_FRAME changed from 31 to 32
Because in VPU_DecRegisterFrameBufCommand()
frameAddr[MAX_REG_FRAME] is an odd array.
In swap_endian(), two addresses are stored.
So, memory corruption occurs.
Signed-off-by: HeynChul Jun <hcjun@nexell.co.kr>
Change-Id: I1278447fd32f4a72ac7667702476f0b2c42d969f
Reviewed-on: https://review.gerrithub.io/c/NexellCorp/linux_kernel-4.4.x/+/450443
Tested-by: Nexell Jenkins <jenkins@nexell.co.kr>
Reviewed-by: SeongO Park <ray@nexell.co.kr>
-rw-r--r-- | drivers/media/platform/nx-vpu/nx_vpu_config.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/platform/nx-vpu/nx_vpu_config.h b/drivers/media/platform/nx-vpu/nx_vpu_config.h index cc30022eb400..8135a0407249 100644 --- a/drivers/media/platform/nx-vpu/nx_vpu_config.h +++ b/drivers/media/platform/nx-vpu/nx_vpu_config.h @@ -82,7 +82,7 @@ #define VPU_GBU_SIZE 1024 /* No modification required */ #define JPU_GBU_SIZE 512 /* No modification required */ -#define MAX_REG_FRAME 31 +#define MAX_REG_FRAME 32 /*---------------------------------------------------------------------------- * Encoder Configurations |