Edward O'Callaghan has uploaded this change for review.

View Change

board_enable.c: Clean up board_handle_phase()

The board_enable_safetycheck() call already checks nullarity
of the function pointer.

Change-Id: I956961ee7204d3a6a9066ba5945f95af1411e700
Signed-off-by: Edward O'Callaghan <quasisec@google.com>
---
M board_enable.c
1 file changed, 14 insertions(+), 6 deletions(-)

git pull ssh://review.coreboot.org:29418/flashrom refs/changes/53/73453/1
diff --git a/board_enable.c b/board_enable.c
index 09c89ae..cebaf56 100644
--- a/board_enable.c
+++ b/board_enable.c
@@ -2707,12 +2707,7 @@
/* FIXME: Should this be identical to board_flash_enable? */
static int board_handle_phase(enum board_match_phase phase, bool force_boardenable)
{
- const struct board_match *board = NULL;
-
- board = board_match_pci_ids(phase);
-
- if (!board)
- return 0;
+ const struct board_match *board = board_match_pci_ids(phase);

if (board_enable_safetycheck(board, force_boardenable))
return 0;

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

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: I956961ee7204d3a6a9066ba5945f95af1411e700
Gerrit-Change-Number: 73453
Gerrit-PatchSet: 1
Gerrit-Owner: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-MessageType: newchange