arm-trusted-firmware/drivers/arm
johpow01 20d384978b Fix casting bug in gicv2_main.c
In the function gicv2_set_spi_routing, the signed value proc_num is cast
to unsigned int before being compared to other unsigned values in two
assert calls.  The value proc_num can be a negative value, and once the
negative value is cast to unsigned it becomes a very large number which
will trigger the assert.  This patch changes the assert cast so that the
unsigned values are cast to signed instead, keeping the same functionality
but allowing proc_num to be negative.

This bug can be seen when running the SDEI RM_ANY routing mode test in
TFTF on the Juno platform.

This patch also makes the usage of the proc_num variable in other gicv2
functions more clear.

Signed-off-by: John Powell <john.powell@arm.com>
Change-Id: If1b98eebb00bd9b73862e5e995e5e68c168170a6
2020-10-10 07:14:44 +00:00
..
cci Sanitise includes across codebase 2019-01-04 10:43:17 +00:00
ccn Coverity: remove unnecessary header file includes 2020-02-04 10:23:51 -06:00
css fconf: Clean confused naming between TB_FW and FW_CONFIG 2020-06-24 08:44:26 +01:00
fvp fvp: pwrc: Move to drivers/ folder 2019-01-25 16:04:11 +00:00
gic Fix casting bug in gicv2_main.c 2020-10-10 07:14:44 +00:00
pl011 pl011: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
pl061 Sanitise includes across codebase 2019-01-04 10:43:17 +00:00
sbsa libc: Consolidate unified definitions 2019-12-06 11:37:19 +01:00
scu drivers: add a driver for snoop control unit 2020-01-03 10:44:28 +00:00
smmu SMMUv3:Changed retry loop to delay timer(GENFW-3329) 2019-11-01 10:51:07 -06:00
sp804 Remove several warnings reported with W=2 2019-04-01 10:43:42 +01:00
sp805 Sanitise includes across codebase 2019-01-04 10:43:17 +00:00
tzc TZ DMC620 driver: Fix MISRA-2012 defects 2020-07-27 15:04:14 +01:00