opaque: Move probing into PREPARE_POST_PROBE hook

To get rid of the flash context in probing, we have to split the
detection of chip parameters out into a preparation step. Below
the opaque-master API, things could actually stay as they are,
we rename `.probe` to `.prepare` though for completeness.

Change-Id: Ic8418e6c5bdc49f5133cdb21efed0bf6dc2f820e
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/449
diff --git a/amd_rom3read.c b/amd_rom3read.c
index 9708ea9..a8c6648 100644
--- a/amd_rom3read.c
+++ b/amd_rom3read.c
@@ -86,7 +86,7 @@
 	return 0;
 }
 
-static int rom3read_probe(struct flashctx *const flash)
+static int rom3read_prepare(struct flashctx *const flash)
 {
 	const struct spi100 *const spi100 = flash->mst.opaque->data;
 	const void *const rom3 = spi100->memory;
@@ -151,7 +151,7 @@
 static const struct opaque_master rom3read_master = {
 	.max_data_read	= MAX_DATA_UNSPECIFIED,
 	.max_data_write	= MAX_DATA_UNSPECIFIED,
-	.probe		= rom3read_probe,
+	.prepare	= rom3read_prepare,
 	.read		= rom3read_read,
 	.write		= rom3read_write,
 	.erase		= rom3read_erase,