Pass programmer context to programmer->init()

Change-Id: I064eb4e25c3d382e4e5bde802306698fafe5e1d0
Signed-off-by: Nico Huber <nico.h@gmx.de>
Reviewed-on: https://review.sourcearcade.org/c/flashprog/+/72526
diff --git a/internal.c b/internal.c
index 5d85758..57064a7 100644
--- a/internal.c
+++ b/internal.c
@@ -162,7 +162,7 @@
 	return 0;
 }
 
-static int internal_init(void)
+static int internal_init(struct flashprog_programmer *const prog)
 {
 	int ret = 0;
 	bool force_laptop;
@@ -189,7 +189,7 @@
 	 */
 	internal_buses_supported = BUS_NONSPI;
 
-	if (try_mtd() == 0) {
+	if (try_mtd(prog) == 0) {
 		ret = 0;
 		goto internal_init_exit;
 	}