arm-trusted-firmware/drivers
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
..
allwinner plat/allwinner: Only enable DRIVEVBUS if really needed 2020-08-17 11:13:59 +01:00
amlogic meson: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
arm Fix casting bug in gicv2_main.c 2020-10-10 07:14:44 +00:00
auth Crypto library: Migrate support to MbedTLS v2.24.0 2020-10-01 11:12:18 +00:00
brcm driver: brcm: add RNG driver 2020-07-13 18:01:19 +05:30
cadence/uart/aarch64 cdns: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
cfi/v2m coverity: fix MISRA violations 2020-02-18 10:47:46 -06:00
console skeletton: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
coreboot/cbmem_console/aarch64 coreboot: Use generic base address 2020-02-25 09:34:38 +00:00
delay_timer include: move MHZ_TICKS_PER_SEC to utils_def.h 2020-02-20 09:25:45 -08:00
gpio Sanitise includes across codebase 2019-01-04 10:43:17 +00:00
imx imx: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
intel/soc/stratix10/io io: change seek offset to signed long long 2020-01-10 21:14:57 +01:00
io Merge "io_fip: return -ENFILE when a file is already open" into integration 2020-07-21 21:41:51 +00:00
marvell marvell: comphy: cp110: add support for USB comphy polarity invert 2020-10-04 15:56:01 +02:00
measured_boot Merge "Measured Boot Driver: Fix MISRA-C 2012 defects" into integration 2020-10-01 18:18:32 +00:00
mentor/i2c Enable -Wlogical-op always 2019-11-19 08:53:21 -06:00
mmc mmc: increase delay between ACMD41 retries 2019-10-03 11:17:31 +02:00
mtd nand: raw_nand: fix timeout issue in nand_wait_ready 2020-09-24 09:32:23 +02:00
partition drivers: partition: support different block size 2019-09-18 18:18:20 +08:00
renesas/rcar rcar: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
rpi3 rpi3: gpio: Simplify GPIO setup 2020-03-17 12:44:09 +00:00
st drivers: stm32_fmc2_nand: fix incorrect error detection 2020-10-08 09:42:04 +02:00
synopsys Merge changes from topic "jc/shift-overflow" into integration 2019-07-16 10:11:27 +00:00
ti/uart 16550: Use generic console_t data structure 2020-02-25 09:34:38 +00:00
ufs drivers: ufs: Extend the delay after reset to wait for some slower chips 2019-05-13 17:11:07 -07:00