coreboot-kgpe-d16/src/mainboard/google/hatch
Edward O'Callaghan 10757897c0 mb/google/hatch/romstage_spd_smbus.c: Fix missing DIMM issue
Since `commit 0ee9b14c09c` the SPD array is set to NULL if no
DIMM is present. This causes failure due to an unconditional use
of `blk.spd_array[i]`, : i={0,1}.

This validates the spd_array is non-NULL before use otherwise it
sets the DIMM as not present.


Puff fails boot with the following log:

```
 ...
SPD: banks 16, ranks 2, rows 16, columns 10, density 8192 Mb
SPD: device width 8 bits, bus width 64 bits
SPD: module size is 16384 MB (per channel)
ASSERTION ERROR: file 'src/soc/intel/cannonlake/cnl_memcfg_init.c', line 47
```

BUG=b:155220125
BRANCH=none
TEST=none

Change-Id: I5f47c849344951d53fa8c67e779b7c46d632d124
Signed-off-by: Edward O'Callaghan <quasisec@google.com>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/40820
Reviewed-by: Jamie Chen <jamie.chen@intel.com>
Reviewed-by: Sam McNally <sammc@google.com>
Reviewed-by: Furquan Shaikh <furquan@google.com>
Reviewed-by: Daniel Kurtz <djkurtz@google.com>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2020-04-29 05:41:07 +00:00
..
spd mainboard/google: Remove copyright notices 2020-03-18 16:44:31 +00:00
variants mb/google/hatch/var/jinlon: Update DPTF parameters 2020-04-27 16:13:07 +00:00
board_info.txt
bootblock.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
chromeos-16MiB.fmd mb/google: Shrink GBB section size 2019-10-18 12:23:54 +00:00
chromeos.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
chromeos.fmd mb/google: Shrink GBB section size 2019-10-18 12:23:54 +00:00
dsdt.asl mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
ec.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
Kconfig mb/google/hatch: Make Kconfig LAPTOP knob transitively select 2020-04-24 03:29:35 +00:00
Kconfig.name mb/google/hatch: Make Kconfig LAPTOP knob transitively select 2020-04-24 03:29:35 +00:00
Makefile.inc mainboard/google: Remove copyright notices 2020-03-18 16:44:31 +00:00
ramstage.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
romstage_spd_cbfs.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00
romstage_spd_smbus.c mb/google/hatch/romstage_spd_smbus.c: Fix missing DIMM issue 2020-04-29 05:41:07 +00:00
smihandler.c mb/google/hatch: Use SPDX for GPL-2.0-only files 2020-04-06 13:49:40 +00:00