Unify programmer parameter extraction
Make programmer_param static by converting all users to extract_programmer_param.
Programmer parameters can no longer be separated with a
colon, they have to be separated with a comma.
Corresponding to flashrom svn r1072.
Signed-off-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
Acked-by: Michael Karcher <flashrom@mkarcher.dialup.fu-berlin.de>
diff --git a/buspirate_spi.c b/buspirate_spi.c
index 4dceca5..e0683ec 100644
--- a/buspirate_spi.c
+++ b/buspirate_spi.c
@@ -101,14 +101,14 @@
char *speed = NULL;
int spispeed = 0x7;
- dev = extract_param(&programmer_param, "dev", ",:");
+ dev = extract_programmer_param("dev");
if (!dev || !strlen(dev)) {
msg_perr("No serial device given. Use flashrom -p "
"buspirate_spi:dev=/dev/ttyUSB0\n");
return 1;
}
- speed = extract_param(&programmer_param, "spispeed", ",:");
+ speed = extract_programmer_param("spispeed");
if (speed) {
for (i = 0; spispeeds[i].name; i++)
if (!strncasecmp(spispeeds[i].name, speed,