tegra: cvnas: Fix type casting issue

CERT-C is reporting following issue:
- Casting cvsram_slice_data[1] from unsigned int to int without checking
its value may result in lost or misinterpreted data.
Fix this by changing the data type of slice_size.

CID 490074
Bug 3745813

Change-Id: Ic52fd016798310b69da69247a6eb2d7a626a4146
Signed-off-by: Ketan Patil <ketanp@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2828530
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
This commit is contained in:
Ketan Patil
2022-12-15 11:52:41 +00:00
committed by Laxman Dewangan
parent 59f352a819
commit 300ceb3ea2

View File

@@ -90,7 +90,7 @@ struct cvnas_device {
struct device dma_dev;
u32 nslices;
int slice_size;
u32 slice_size;
phys_addr_t cvsram_base;
size_t cvsram_size;