arm-trusted-firmware/common
Andre Przywara 4276cfe2fa fdt: Fix coverity complaint about 32-bit multiplication
Coverity raised an eyebrow over our GICR frame size calculation:
========
    CID 362942:  Integer handling issues  (OVERFLOW_BEFORE_WIDEN)
Potentially overflowing expression "nr_cores * gicr_frame_size" with type
"unsigned int" (32 bits, unsigned) is evaluated using 32-bit arithmetic,
and then used in a context that expects an expression of type "uint64_t"
(64 bits, unsigned).
========

Even with a GICv4 (256KB frame size) we need 16384 cores to overflow
32-bit, so it's not a practical issue.

But it's also easy to fix, so let's just do that: cast gicr_frame_size
to an unsigned 64-bit integer, so that the multiplication is done in the
64-bit realm.

Change-Id: Iad10e19b9e58d5fbf9d13205fbcef0aac5ae48af
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
2020-10-07 11:13:48 +01:00
..
aarch32 Align AARCH32 version of debug.S with AARCH64 2020-09-21 17:53:42 +02:00
aarch64 Align AARCH32 version of debug.S with AARCH64 2020-09-21 17:53:42 +02:00
backtrace Add wrapper for AT instruction 2020-08-18 10:49:27 +01:00
bl_common.c fconf: Add TBBR disable_authentication property 2020-02-07 13:51:32 +00:00
desc_image_load.c SPMD: extract SPMC DTB header size from SPMD 2020-05-13 08:08:39 +02:00
fdt_fixup.c fdt: Fix coverity complaint about 32-bit multiplication 2020-10-07 11:13:48 +01:00
fdt_wrappers.c plat/fvp: Support for extracting UART serial node info from DT 2020-05-20 21:41:50 -05:00
image_decompress.c Sanitise includes across codebase 2019-01-04 10:43:17 +00:00
runtime_svc.c Remove support for the SMC Calling Convention 2.0 2019-01-30 16:01:49 +00:00
tf_log.c Remove references to old project name from common files 2019-07-10 11:13:00 +01:00