Thread (9 messages) 9 messages, 2 authors, 2021-12-13

Re: [iproute2-next 3/4] vdpa: Enable user to set mac address of vdpa device

flat view

From: David Ahern <hidden>
Date: 2021-12-03 17:05:27
Also in: virtualization

On 12/1/21 9:22 PM, Parav Pandit wrote:
quoted hunk ↗ jump to hunk
@@ -233,6 +254,15 @@ static int vdpa_argv_parse(struct vdpa *vdpa, int argc, char **argv,
 
 			NEXT_ARG_FWD();
 			o_found |= VDPA_OPT_VDEV_MGMTDEV_HANDLE;
+		} else if ((matches(*argv, "mac")  == 0) &&
use strcmp; we are not taking any more uses of matches() for parameters.

quoted hunk ↗ jump to hunk
+			   (o_all & VDPA_OPT_VDEV_MAC)) {
+			NEXT_ARG_FWD();
+			err = vdpa_argv_mac(vdpa, argc, argv, opts->mac);
+			if (err)
+				return err;
+
+			NEXT_ARG_FWD();
+			o_found |= VDPA_OPT_VDEV_MAC;
 		} else {
 			fprintf(stderr, "Unknown option \"%s\"\n", *argv);
 			return -EINVAL;
  
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help