Revert DSCP update changes.
authorBen Pfaff <blp@nicira.com>
Wed, 20 Jun 2012 16:31:42 +0000 (09:31 -0700)
committerBen Pfaff <blp@nicira.com>
Wed, 20 Jun 2012 16:59:09 +0000 (09:59 -0700)
This reverts commit cd8fca2ba0a7d036da069a4484d501bdc7a6f611 (jsonrpc:
Correctly setting the dscp value before reconnect.) and commit
b2e18db292cd4962af3248f11e9f17e6eaf9c033 (No need to restart DB / OVS on
changing dscp value.), which on some systems causes numerous unit test
failures that valgrind diagnoses as:

Conditional jump or move depends on uninitialised value(s)
   at 0x805F63F: jsonrpc_session_set_dscp (jsonrpc.c:1061)
   by 0x804F45D: ovsdb_jsonrpc_server_set_remotes (jsonrpc-server.c:417)
   by 0x804B775: reconfigure_from_db (ovsdb-server.c:656)
   by 0x804C231: main (ovsdb-server.c:159)

Signed-off-by: Ben Pfaff <blp@nicira.com>
lib/jsonrpc.c
lib/rconn.c
lib/rconn.h
ofproto/connmgr.c
vswitchd/vswitch.xml

index 4870da842627b94f05919919d410f7f6360d0847..5c3359cb241d929ee1c1f1b5f03237d34d8bc3ff 100644 (file)
@@ -1058,8 +1058,5 @@ void
 jsonrpc_session_set_dscp(struct jsonrpc_session *s,
                          uint8_t dscp)
 {
 jsonrpc_session_set_dscp(struct jsonrpc_session *s,
                          uint8_t dscp)
 {
-    if (s->dscp != dscp) {
-        s->dscp = dscp;
-        jsonrpc_session_force_reconnect(s);
-    }
+    s->dscp = dscp;
 }
 }
index 3241ab8bdf7cf92a0fc17d991e175ad3df150b3f..2ddfc69ada40304ca30906a1c7526cd75cba0892 100644 (file)
@@ -226,12 +226,6 @@ rconn_set_dscp(struct rconn *rc, uint8_t dscp)
     rc->dscp = dscp;
 }
 
     rc->dscp = dscp;
 }
 
-uint8_t
-rconn_get_dscp(const struct rconn *rc)
-{
-    return rc->dscp;
-}
-
 void
 rconn_set_probe_interval(struct rconn *rc, int probe_interval)
 {
 void
 rconn_set_probe_interval(struct rconn *rc, int probe_interval)
 {
index e4b73fc1909de5d651a274171f39860f065fff7e..2b1332c5f9d25b2fc2d5f916cf5ffa7a56754467 100644 (file)
@@ -40,7 +40,6 @@ struct rconn_packet_counter;
 struct rconn *rconn_create(int inactivity_probe_interval,
                           int max_backoff, uint8_t dscp);
 void rconn_set_dscp(struct rconn *rc, uint8_t dscp);
 struct rconn *rconn_create(int inactivity_probe_interval,
                           int max_backoff, uint8_t dscp);
 void rconn_set_dscp(struct rconn *rc, uint8_t dscp);
-uint8_t rconn_get_dscp(const struct rconn *rc);
 void rconn_set_max_backoff(struct rconn *, int max_backoff);
 int rconn_get_max_backoff(const struct rconn *);
 void rconn_set_probe_interval(struct rconn *, int inactivity_probe_interval);
 void rconn_set_max_backoff(struct rconn *, int max_backoff);
 int rconn_get_max_backoff(const struct rconn *);
 void rconn_set_probe_interval(struct rconn *, int inactivity_probe_interval);
index 8cdaa1f80bdf7c45eacfc45427b92842a5419901..a0315b23fe9f0f6b2868c4cb71f1aad2a92b8263 100644 (file)
@@ -1114,12 +1114,6 @@ ofconn_reconfigure(struct ofconn *ofconn, const struct ofproto_controller *c)
     rconn_set_probe_interval(ofconn->rconn, probe_interval);
 
     ofconn_set_rate_limit(ofconn, c->rate_limit, c->burst_limit);
     rconn_set_probe_interval(ofconn->rconn, probe_interval);
 
     ofconn_set_rate_limit(ofconn, c->rate_limit, c->burst_limit);
-
-    /* If dscp value changed reconnect. */
-    if (c->dscp != rconn_get_dscp(ofconn->rconn)) {
-        rconn_set_dscp(ofconn->rconn, c->dscp);
-        rconn_reconnect(ofconn->rconn);
-    }
 }
 
 /* Returns true if it makes sense for 'ofconn' to receive and process OpenFlow
 }
 
 /* Returns true if it makes sense for 'ofconn' to receive and process OpenFlow
index 15f162a18effc565a347226263b6033a27781bfa..32d4c595b20c1a412358df72685005d5392aea8d 100644 (file)
         Service (QoS) on IP networks.
 
         The DSCP value specified here is used when establishing the connection
         Service (QoS) on IP networks.
 
         The DSCP value specified here is used when establishing the connection
-        between the controller and the Open vSwitch.  If no value is specified,
-        a default value of 48 is chosen.  Valid DSCP values must be in the
-        range 0 to 63.
+        between the controller and the Open vSwitch.  The connection must be
+        reset for the new DSCP values to take effect.  If no value is
+        specified, a default value of 48 is chosen.  Valid DSCP values must be
+        in the range 0 to 63.
       </column>
     </group>
 
       </column>
     </group>
 
         Service (QoS) on IP networks.
 
         The DSCP value specified here is used when establishing the connection
         Service (QoS) on IP networks.
 
         The DSCP value specified here is used when establishing the connection
-        between the manager and the Open vSwitch.  If no value is specified, a
-        default value of 48 is chosen.  Valid DSCP values must be in the range
-        0 to 63.
+        between the manager and the Open vSwitch.  The connection must be
+        reset for the new DSCP values to take effect.  If no value is
+        specified, a default value of 48 is chosen.  Valid DSCP values must be
+        in the range 0 to 63.
       </column>
     </group>
 
       </column>
     </group>