coreboot/src/soc
Martin Kepplinger 9460a986e1 soc/amd/stoneyridge/northbridge.c: remove unnecessary null check
Checking for NULL here doesn't help here. We *rely* on cdb_dev to exist
directly before this check. Coverity had found this:

*** CID 1376664:  Null pointer dereferences  (REVERSE_INULL)
/src/soc/amd/stoneyridge/northbridge.c: 666 in cpu_bus_scan()
660     	  * this silicon. It is an SOC and can't have  >= 16 APICs, but
661     	  * we will start numbering at 0x10. We also know there is only
662     	  * on physical node (module in AMD speak).
663     	  */
664
665     	lapicid_start = 0x10; /* Get this from devicetree? see comment above. */

CID 1376664:  Null pointer dereferences  (REVERSE_INULL)
Null-checking "cdb_dev" suggests that it may be null, but it has already been
dereferenced on all paths leading to the check.

666     	enable_node = cdb_dev && cdb_dev->enabled;
667     	cpu_bus = dev->link_list;
668
669     	for (j = 0; j <= siblings; j++ ) {
670     		apic_id = lapicid_start + j;
671     		printk(BIOS_SPEW, "lapicid_start 0x%x, node 0x%x,  core 0x%x,  apicid=0x%x\n",

Change-Id: Ic6a53df8b8d1596ad0eb1d8f0fa200cccf9509cf
Signed-off-by: Martin Kepplinger <martink@posteo.de>
Reviewed-on: https://review.coreboot.org/20415
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Martin Roth <martinroth@google.com>
2017-07-08 19:07:18 +00:00
..
amd soc/amd/stoneyridge/northbridge.c: remove unnecessary null check 2017-07-08 19:07:18 +00:00
broadcom/cygnus soc/broadcom/cygnus: Move spi driver to use spi_bus_map 2017-05-24 04:39:30 +02:00
dmp/vortex86ex Consolidate reset API, add generic reset_prepare mechanism 2017-06-13 20:53:09 +02:00
imgtec/pistachio Consolidate reset API, add generic reset_prepare mechanism 2017-06-13 20:53:09 +02:00
intel soc/intel/quark: Add I2C debugging 2017-07-03 23:30:50 +00:00
lowrisc/lowrisc
marvell/mvmap2315 soc/marvell/armada38x: Remove unused SoC armada38x 2017-05-24 04:43:23 +02:00
mediatek/mt8173 Consolidate reset API, add generic reset_prepare mechanism 2017-06-13 20:53:09 +02:00
nvidia device/Kconfig: Introduce MAINBOARD_FORCE_NATIVE_VGA_INIT 2017-06-08 14:31:43 +02:00
qualcomm spi: Remove unused/unnecessary spi_init function definitions 2017-06-07 22:49:37 +02:00
rockchip rockchip/rk3399: update the ddr 200MHz frequency configuration 2017-06-26 00:45:02 +00:00
samsung Consolidate reset API, add generic reset_prepare mechanism 2017-06-13 20:53:09 +02:00
ucb/riscv