Attention is currently required from: Sam McNally, Edward O'Callaghan, Angel Pons.

Nico Huber would like Sam McNally, build bot (Jenkins), Edward O'Callaghan and Angel Pons to review this change.

View Change

chipset_enable.c: Validate physmap() return rcrb value

Validate the physical mapping in enable_flash_silvermont().

Change-Id: Icc5a799a06b3f310d9a191fa5eb99b255b20d79d
Signed-off-by: Edward O'Callaghan <quasisec@google.com>
Reviewed-on: https://review.coreboot.org/c/flashrom/+/48225
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Sam McNally <sammc@google.com>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
---
M chipset_enable.c
1 file changed, 18 insertions(+), 0 deletions(-)

git pull ssh://review.coreboot.org:29418/flashrom refs/changes/68/67868/1
diff --git a/chipset_enable.c b/chipset_enable.c
index 5195b95..bbd0465 100644
--- a/chipset_enable.c
+++ b/chipset_enable.c
@@ -988,6 +988,8 @@

/* Handle GCS (in RCRB) */
void *rcrb = physmap("BYT RCRB", rcba, 4);
+ if (rcrb == ERROR_PTR)
+ return ERROR_FATAL;
const enum chipbustype boot_buses = enable_flash_ich_report_gcs(dev, ich_generation, rcrb);
physunmap(rcrb, 4);


To view, visit change 67868. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: 1.2.x
Gerrit-Change-Id: Icc5a799a06b3f310d9a191fa5eb99b255b20d79d
Gerrit-Change-Number: 67868
Gerrit-PatchSet: 1
Gerrit-Owner: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-Reviewer: Sam McNally <sammc@google.com>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-Attention: Sam McNally <sammc@google.com>
Gerrit-Attention: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-Attention: Angel Pons <th3fanbus@gmail.com>
Gerrit-MessageType: newchange