When both --scan and device name is passed to --stop action,
then is executed only for given device. Scan is ignored.
Block the operation when both --scan and device name are passed.
Signed-off-by: Norbert Szulc <norbert.szulc@intel.com>
Signed-off-by: Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
rv |= Manage_run(dv->devname, mdfd, c);
break;
case 'S':
+ if (c->scan) {
+ pr_err("--stop not meaningful with both a --scan assembly and a device name.\n");
+ rv |= 1;
+ break;
+ }
rv |= Manage_stop(dv->devname, mdfd, c->verbose, 0);
break;
case 'o':