summaryrefslogtreecommitdiffstats
path: root/internal.c
diff options
context:
space:
mode:
authorAngel Pons <th3fanbus@gmail.com>2022-09-21 09:45:47 +0200
committerFelix Singer <felixsinger@posteo.net>2022-09-21 13:42:45 +0000
commit496331a6727d146145f843141e6bc0a1e73b60ff (patch)
tree37d22dfcb7a97a37dad938b064b7a77098e55c7c /internal.c
parent5363f35fa03e4db2cd79032ca9860c0c5382a355 (diff)
downloadflashrom-496331a6727d146145f843141e6bc0a1e73b60ff.tar.gz
flashrom-496331a6727d146145f843141e6bc0a1e73b60ff.tar.bz2
flashrom-496331a6727d146145f843141e6bc0a1e73b60ff.zip
internal.c: Pass `programmer_cfg` to `try_mtd()`
Programmer params are now passed via the `programmer_cfg` struct, but the internal programmer did not pass them to the `try_mtd()` function which was still using `NULL`. This problem resulted in a segmentation fault when trying to use the internal programmer. TEST=Make sure internal programmer does not segfault on Haswell ULT. Change-Id: I9e74bd68a1f9509a201dc518dbff96c27d68a3c3 Signed-off-by: Angel Pons <th3fanbus@gmail.com> Reviewed-on: https://review.coreboot.org/c/flashrom/+/67752 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Thomas Heijligen <src@posteo.de> Reviewed-by: Felix Singer <felixsinger@posteo.net> Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Diffstat (limited to 'internal.c')
-rw-r--r--internal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/internal.c b/internal.c
index 43aa51bcd..6a8db5e6d 100644
--- a/internal.c
+++ b/internal.c
@@ -215,7 +215,7 @@ static int internal_init(const struct programmer_cfg *cfg)
*/
internal_buses_supported = BUS_NONSPI;
- if (try_mtd() == 0) {
+ if (try_mtd(cfg) == 0) {
ret = 0;
goto internal_init_exit;
}