Home
last modified time | relevance | path

Searched hist:"3 ef5820c43e9feeff00b0e5722959b89b141610f" (Results 1 – 1 of 1) sorted by relevance

/rk3399_ARM-atf/plat/xilinx/versal_net/
H A Dbl31_versal_net_setup.c3ef5820c43e9feeff00b0e5722959b89b141610f Wed Sep 03 09:26:13 UTC 2025 Saivardhan Thatikonda <saivardhan.thatikonda@amd.com> fix(versal-net): fix coverity violation prevent buffer overrun

Coverity reported potential memory corruption issues in
bl31_early_platform_setup2() (CIDs 487973 and 487972):

- CID 487973 (ARRAY_VS_SINGLETON): "&boot_mode" was passed to
get_boot_mode(), which treats the argument as an array. This could
lead to misinterpretation of adjacent memory.
- CID 487972 (OVERRUN): Passing "&boot_mode" (a single 4-byte element)
allowed get_boot_mode() to access out-of-bounds indices, resulting in
a possible buffer overrun.

Changed boot_mode from a single variable to an array sized according
to the return payload, preventing singleton pointer violation.

Change-Id: I53944db10b694d1599da0e5b1fbd30a97e83803c
Signed-off-by: Saivardhan Thatikonda <saivardhan.thatikonda@amd.com>