mirror of
https://review.coreboot.org/flashrom.git
synced 2025-04-26 22:52:34 +02:00
flashrom.c: Use programmer_init() func params over global
The 'programmer' intended to be used in the control flow of 'programmer_init()' is a parameter to the function. Therefore use that symbol directly over the global copy of it. Change-Id: I71e61f0633bac2fc472971249910bf3bf57cd0eb Signed-off-by: Edward O'Callaghan <quasisec@google.com> Reviewed-on: https://review.coreboot.org/c/flashrom/+/68249 Reviewed-by: Angel Pons <th3fanbus@gmail.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
This commit is contained in:
parent
001c87d901
commit
890d07986b
@ -161,8 +161,8 @@ int programmer_init(const struct programmer_entry *prog, const char *param)
|
||||
cfg.params = NULL;
|
||||
}
|
||||
|
||||
msg_pdbg("Initializing %s programmer\n", programmer->name);
|
||||
ret = programmer->init(&cfg);
|
||||
msg_pdbg("Initializing %s programmer\n", prog->name);
|
||||
ret = prog->init(&cfg);
|
||||
if (cfg.params && strlen(cfg.params)) {
|
||||
if (ret != 0) {
|
||||
/* It is quite possible that any unhandled programmer parameter would have been valid,
|
||||
|
Loading…
x
Reference in New Issue
Block a user