Browse Source

Remove support for comma-separated values in --device, and update documentation

Luke Dashjr 12 years ago
parent
commit
5f2eb03560
2 changed files with 3 additions and 4 deletions
  1. 1 1
      README
  2. 2 3
      miner.c

+ 1 - 1
README

@@ -213,7 +213,7 @@ Options for both config file and command line:
 --compact           Use compact display without per device statistics
 --debug|-D          Enable debug output
 --debuglog          Enable debug logging
---device|-d <arg>   Select device to use, one value, range and/or comma separated (e.g. 0-2,4) default: all
+--device|-d <arg>   Enable only devices matching pattern (default: all)
 --disable-rejecting Automatically disable pools that continually reject shares
 --http-port <arg>   Port number to listen on for HTTP getwork miners (-1 means disabled) (default: -1)
 --expiry|-E <arg>   Upper bound on how many seconds after getting work we consider a share from it stale (w/o longpoll active) (default: 120)

+ 2 - 3
miner.c

@@ -1157,8 +1157,7 @@ static char *set_devices(char *arg)
 	} else
 		return "Invalid device parameters";
 
-	for (const char *item = strtok(arg, ","); item; item = strtok(NULL, ","))
-		string_elist_add(item, &opt_devices_enabled_list);
+	string_elist_add(arg, &opt_devices_enabled_list);
 
 	return NULL;
 }
@@ -1782,7 +1781,7 @@ static struct opt_table opt_config_table[] = {
 			"Verbose dump of device protocol-level activities"),
 	OPT_WITH_ARG("--device|-d",
 		     set_devices, NULL, NULL,
-	             "Select device to use, one value, range and/or comma separated (e.g. 0-2,4) default: all"),
+	             "Enable only devices matching pattern (default: all)"),
 	OPT_WITHOUT_ARG("--disable-rejecting",
 			opt_set_bool, &opt_disable_pool,
 			"Automatically disable pools that continually reject shares"),