dpif: Remove obsolete support for datapaths whose names begin with "nl:".
authorBen Pfaff <blp@nicira.com>
Tue, 16 Jun 2009 18:05:00 +0000 (11:05 -0700)
committerBen Pfaff <blp@nicira.com>
Mon, 6 Jul 2009 16:07:24 +0000 (09:07 -0700)
The use of "nl:" as a prefix for datapath names has been deprecated for
months.  That should be long enough for users to update their scripts.

lib/dpif.c
lib/dpif.man
utilities/ovs-dpctl.8.in
vswitchd/bridge.c
vswitchd/ovs-vswitchd.conf.5.in

index 8e8cfcd..877cfc8 100644 (file)
@@ -151,13 +151,7 @@ dpif_create(const char *name, struct dpif **dpifp)
             return error;
         }
 
-        if (!strncmp(name, "nl:", 3)) {
-            char devname[128];
-            sprintf(devname, "of%u", minor);
-            error = ioctl(dpif->fd, ODP_DP_CREATE, devname) < 0 ? errno : 0;
-        } else {
-            error = ioctl(dpif->fd, ODP_DP_CREATE, name) < 0 ? errno : 0;
-        }
+        error = ioctl(dpif->fd, ODP_DP_CREATE, name) < 0 ? errno : 0;
         if (!error) {
             *dpifp = dpif;
         } else {
@@ -1032,10 +1026,6 @@ get_minor_from_name(const char *name, unsigned int *minor)
     if (!strncmp(name, "dp", 2) && isdigit(name[2])) {
         *minor = atoi(name + 2);
         return 0;
-    } else if (!strncmp(name, "nl:", 3) && isdigit(name[3])) {
-        /* This is for compatibility only and will be dropped. */
-        *minor = atoi(name + 3);
-        return 0;
     } else {
         return EINVAL;
     }
index 72175b0..3a58caf 100644 (file)
@@ -9,8 +9,3 @@ inclusive.
 The name of the network device associated with the datapath's local
 port.  (\fB\*(PN\fR internally converts this into a datapath number,
 as above.)
-
-.TP
-\fBnl:\fIN\fR
-This is an obsolete synonym for \fBdp\fIN\fR.
-.RE
index 652ebb1..c43d4ff 100644 (file)
@@ -41,14 +41,13 @@ The following commands manage datapaths.
 
 Creates datapath \fIdp\fR.  The name of the new datapath's local port
 depends on how \fIdp\fR is specified: if it takes the form
-\fBdp\fIN\fR, the local port will be named \fBdp\fIN\fR; if \fIdp\fR
-is \fBnl:\fI, the local port will be named \fBof\fIN\fR; otherwise,
+\fBdp\fIN\fR, the local port will be named \fBdp\fIN\fR; otherwise,
 the local port's name will be \fIdp\fR.
 
 This will fail if the host already has 256 datapaths, if a network
 device with the same name as the new datapath's local port already
-exists, or if \fIdp\fR is given in the form \fBdp\fIN\fR or
-\fBnl:\fIN\fR and a datapath numbered \fIN\fR already exists.
+exists, or if \fIdp\fR is given in the form \fBdp\fIN\fR
+and a datapath numbered \fIN\fR already exists.
 
 If \fInetdev\fRs are specified, \fBovs\-dpctl\fR adds them to the datapath.
 
index ebf525f..da80eed 100644 (file)
@@ -369,10 +369,9 @@ bridge_reconfigure(void)
     svec_init(&new_br);
     for (i = 0; i < raw_new_br.n; i++) {
         const char *name = raw_new_br.names[i];
-        if ((!strncmp(name, "dp", 2) && isdigit(name[2])) ||
-            (!strncmp(name, "nl:", 3) && isdigit(name[3]))) {
+        if (!strncmp(name, "dp", 2) && isdigit(name[2])) {
             VLOG_ERR("%s is not a valid bridge name (bridges may not be "
-                     "named \"dp\" or \"nl:\" followed by a digit)", name);
+                     "named \"dp\" followed by a digit)", name);
         } else {
             svec_add(&new_br, name);
         }
index 00a0d1e..5483ad5 100644 (file)
@@ -51,7 +51,7 @@ configure \fBovs\-vswitchd\fR.
 A bridge (switch) with a given \fIname\fR is configured by specifying
 the names of its network devices as values for key
 \fBbridge.\fIname\fB.port\fR.  (The specified \fIname\fR may not begin
-with \fBdp\fR or \fBnl:\fR followed by a digit.)
+with \fBdp\fR followed by a digit.)
 .PP
 The names given on \fBbridge.\fIname\fB.port\fR must be the names of
 existing network devices, except for ``internal ports.''  An internal