edi: Split preparation/finalization out of edi_probe_kb9012()
This turns edi_probe_kb9012() into a pure probing function. To avoid
turning EDI off after probing, register edi_finish() only after full
preparation.
Change-Id: Icc342b8ab109d5621d8b65c79cecf71a44bea4bd
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/423
diff --git a/flashchips.c b/flashchips.c
index 37f85b6..02aaf88 100644
--- a/flashchips.c
+++ b/flashchips.c
@@ -4205,6 +4205,7 @@
.read = edi_chip_read,
.voltage = {2700, 3600},
.gran = write_gran_128bytes,
+ .prepare_access = edi_prepare,
},
{