probing: Pass full struct flashchip into probes
In case we want to probe for a particular chip, we can filter the
actual probing sequences by its properties.
We'll use `struct flashchip` internally and `struct flashprog_chip`
will be used only close to the libflashprog API. This way, we can
separate the two later again if necessary.
Change-Id: Id8b13d28fcaefee62746c9391fe86b4b3b09a428
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/441
diff --git a/include/chipdrivers/edi.h b/include/chipdrivers/edi.h
index 3a1d768..4d641cc 100644
--- a/include/chipdrivers/edi.h
+++ b/include/chipdrivers/edi.h
@@ -22,8 +22,9 @@
struct flashprog_flashctx;
struct master_common;
struct bus_probe;
+struct flashchip;
-struct found_id *probe_edi(const struct bus_probe *, const struct master_common *);
+struct found_id *probe_edi(const struct bus_probe *, const struct master_common *, const struct flashchip *chip);
int edi_chip_block_erase(struct flashprog_flashctx *, unsigned int page, unsigned int size);
int edi_chip_write(struct flashprog_flashctx *, const uint8_t *buf, unsigned int start, unsigned int len);