@@ -683,7 +683,7 @@ netdev_dummy_construct(struct netdev *netdev_)
netdev->hwaddr.ea[4] = n >> 8;
netdev->hwaddr.ea[5] = n;
netdev->mtu = 1500;
- netdev->flags = 0;
+ netdev->flags = NETDEV_UP;
netdev->ifindex = -EOPNOTSUPP;
netdev->requested_n_rxq = netdev_->n_rxq;
netdev->requested_n_txq = netdev_->n_txq;
@@ -713,7 +713,7 @@ AT_CHECK([ovs-ofctl -O OpenFlow12 add-group br0 'group_id=1234,type=ff,bucket=wa
AT_CHECK([ovs-ofctl -O OpenFlow12 add-flow br0 'ip actions=write_actions(group:1234)'])
AT_CHECK([ovs-appctl ofproto/trace br0 'in_port=1,dl_src=50:54:00:00:00:05,dl_dst=50:54:00:00:00:07,dl_type=0x0800,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_proto=1,nw_tos=0,nw_ttl=128,icmp_type=8,icmp_code=0'], [0], [stdout])
AT_CHECK([tail -1 stdout], [0],
- [Datapath actions: drop
+ [Datapath actions: 10
])
OVS_VSWITCHD_STOP
AT_CLEANUP
@@ -2395,13 +2395,13 @@ OVS_APP_EXIT_AND_WAIT(ovs-ofctl)
AT_CHECK([strip_metadata < ofctl_monitor.log], [0], [dnl
NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
-tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
+tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
dnl
NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
-tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
+tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
dnl
NXT_PACKET_IN (xid=0x0): cookie=0xd total_len=58 in_port=1 (via action) data_len=58 (unbuffered)
-tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.255.255,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7745
+tcp,vlan_tci=0x0000,dl_src=60:66:66:66:00:06,dl_dst=50:54:00:00:00:07,nw_src=192.168.0.1,nw_dst=192.168.0.2,nw_tos=0,nw_ecn=0,nw_ttl=255,tp_src=80,tp_dst=0,tcp_flags=0 tcp_csum:7744
])
AT_CHECK([ovs-appctl time/warp 5000], [0], [ignore])
@@ -6228,7 +6228,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=202
in_unicasts=3
in_multicasts=4294967295
@@ -6251,7 +6251,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=148
in_unicasts=2
in_multicasts=4294967295
@@ -6274,7 +6274,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=0
in_unicasts=0
in_multicasts=4294967295
@@ -6297,7 +6297,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=0
in_unicasts=0
in_multicasts=4294967295
@@ -6320,7 +6320,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=202
in_unicasts=3
in_multicasts=4294967295
@@ -6343,7 +6343,7 @@ IFCOUNTERS
type=6
ifspeed=100000000
direction=0
- status=0
+ status=3
in_octets=148
in_unicasts=2
in_multicasts=4294967295
@@ -39,8 +39,8 @@ n_tables:254, n_buffers:0
capabilities: FLOW_STATS TABLE_STATS PORT_STATS QUEUE_STATS ARP_MATCH_IP
actions: output enqueue set_vlan_vid set_vlan_pcp strip_vlan mod_dl_src mod_dl_dst mod_nw_src mod_nw_dst mod_nw_tos mod_tp_src mod_tp_dst
LOCAL(br0): addr:aa:55:aa:55:00:00
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max
OFPT_GET_CONFIG_REPLY: frags=normal miss_send_len=0
])
@@ -61,16 +61,16 @@ n_tables:254, n_buffers:0
capabilities: FLOW_STATS TABLE_STATS PORT_STATS QUEUE_STATS ARP_MATCH_IP
actions: output enqueue set_vlan_vid set_vlan_pcp strip_vlan mod_dl_src mod_dl_dst mod_nw_src mod_nw_dst mod_nw_tos mod_tp_src mod_tp_dst
1(p1): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max
99(p2): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max
LOCAL(br0): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max
OFPT_GET_CONFIG_REPLY: frags=normal miss_send_len=0
])
@@ -125,8 +125,8 @@ AT_CHECK([ovs-ofctl -vwarn dump-ports-desc br0], [0], [stdout])
AT_CHECK([strip_xids < stdout], [0], [dnl
OFPST_PORT_DESC reply:
LOCAL(br0): addr:aa:55:aa:55:00:00
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max
])
OVS_VSWITCHD_STOP
@@ -140,8 +140,8 @@ AT_CHECK([ovs-ofctl -O OpenFlow12 -vwarn dump-ports-desc br0], [0], [stdout])
AT_CHECK([strip_xids < stdout], [0], [dnl
OFPST_PORT_DESC reply (OF1.2):
LOCAL(br0): addr:aa:55:aa:55:00:00
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
])
OVS_VSWITCHD_STOP
@@ -154,28 +154,28 @@ AT_CHECK([ovs-ofctl -F OXM-OpenFlow15 -O OpenFlow15 -vwarn dump-ports-desc br0],
AT_CHECK([strip_xids < stdout | sed 's/00:0./00:0x/'], [0], [dnl
OFPST_PORT_DESC reply (OF1.5):
1(p1): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
2(p2): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
3(p3): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
LOCAL(br0): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
])
AT_CHECK([ovs-ofctl -F OXM-OpenFlow15 -O OpenFlow15 -vwarn dump-ports-desc br0 2], [0], [stdout])
AT_CHECK([strip_xids < stdout | sed 's/00:0./00:0x/'], [0], [dnl
OFPST_PORT_DESC reply (OF1.5):
2(p2): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
])
OVS_VSWITCHD_STOP
@@ -188,28 +188,28 @@ AT_CHECK([ovs-ofctl -F OXM-OpenFlow16 -O OpenFlow16 -vwarn dump-ports-desc br0],
AT_CHECK([strip_xids < stdout | sed 's/00:0./00:0x/'], [0], [dnl
OFPST_PORT_DESC reply (OF1.6):
1(p1): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
2(p2): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
3(p3): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
LOCAL(br0): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
])
AT_CHECK([ovs-ofctl -F OXM-OpenFlow16 -O OpenFlow16 -vwarn dump-ports-desc br0 2], [0], [stdout])
AT_CHECK([strip_xids < stdout | sed 's/00:0./00:0x/'], [0], [dnl
OFPST_PORT_DESC reply (OF1.6):
2(p2): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max
])
OVS_VSWITCHD_STOP
@@ -1265,16 +1265,17 @@ OVS_VSWITCHD_START
for command_config_state in \
'up 0 0' \
'noflood NO_FLOOD 0' \
- 'down PORT_DOWN,NO_FLOOD LINK_DOWN' \
- 'flood PORT_DOWN LINK_DOWN' \
- 'no-receive PORT_DOWN,NO_RECV LINK_DOWN' \
- 'no-forward PORT_DOWN,NO_RECV,NO_FWD LINK_DOWN' \
- 'no-packet-in PORT_DOWN,NO_RECV,NO_FWD,NO_PACKET_IN LINK_DOWN' \
- 'forward PORT_DOWN,NO_RECV,NO_PACKET_IN LINK_DOWN' \
- 'packet-in PORT_DOWN,NO_RECV LINK_DOWN' \
+ 'flood 0 0' \
+ 'no-receive NO_RECV 0' \
+ 'no-forward NO_RECV,NO_FWD 0' \
+ 'no-packet-in NO_RECV,NO_FWD,NO_PACKET_IN 0' \
+ 'forward NO_RECV,NO_PACKET_IN 0' \
+ 'packet-in NO_RECV 0' \
'up NO_RECV 0' \
- 'receive 0 0'
+ 'receive 0 0' \
+ 'down PORT_DOWN LINK_DOWN'
do
+ printf '\n--- %s --- \n\n' "$command_config_state"
set $command_config_state
command=$[1] config=`echo $[2] | sed 's/,/ /g'` state=$[3]
AT_CHECK([ovs-ofctl -vwarn mod-port br0 br0 $command])
@@ -1298,15 +1299,16 @@ AT_SETUP([ofproto - mod-port (OpenFlow 1.2)])
OVS_VSWITCHD_START
for command_config_state in \
'up 0 LIVE' \
- 'down PORT_DOWN LINK_DOWN' \
- 'no-receive PORT_DOWN,NO_RECV LINK_DOWN' \
- 'no-forward PORT_DOWN,NO_RECV,NO_FWD LINK_DOWN' \
- 'no-packet-in PORT_DOWN,NO_RECV,NO_FWD,NO_PACKET_IN LINK_DOWN' \
- 'forward PORT_DOWN,NO_RECV,NO_PACKET_IN LINK_DOWN' \
- 'packet-in PORT_DOWN,NO_RECV LINK_DOWN' \
+ 'no-receive NO_RECV LIVE' \
+ 'no-forward NO_RECV,NO_FWD LIVE' \
+ 'no-packet-in NO_RECV,NO_FWD,NO_PACKET_IN LIVE' \
+ 'forward NO_RECV,NO_PACKET_IN LIVE' \
+ 'packet-in NO_RECV LIVE' \
'up NO_RECV LIVE' \
- 'receive 0 LIVE'
+ 'receive 0 LIVE' \
+ 'down PORT_DOWN LINK_DOWN'
do
+ printf '\n--- %s --- \n\n' "$command_config_state"
set $command_config_state
command=$[1] config=`echo $[2] | sed 's/,/ /g'` state=$[3]
AT_CHECK([ovs-ofctl -O OpenFlow12 -vwarn mod-port br0 br0 $command])
@@ -1329,15 +1331,16 @@ AT_SETUP([ofproto - mod-port (OpenFlow 1.4)])
OVS_VSWITCHD_START
for command_config_state in \
'up 0 LIVE' \
- 'down PORT_DOWN LINK_DOWN' \
- 'no-receive PORT_DOWN,NO_RECV LINK_DOWN' \
- 'no-forward PORT_DOWN,NO_RECV,NO_FWD LINK_DOWN' \
- 'no-packet-in PORT_DOWN,NO_RECV,NO_FWD,NO_PACKET_IN LINK_DOWN' \
- 'forward PORT_DOWN,NO_RECV,NO_PACKET_IN LINK_DOWN' \
- 'packet-in PORT_DOWN,NO_RECV LINK_DOWN' \
+ 'no-receive NO_RECV LIVE' \
+ 'no-forward NO_RECV,NO_FWD LIVE' \
+ 'no-packet-in NO_RECV,NO_FWD,NO_PACKET_IN LIVE' \
+ 'forward NO_RECV,NO_PACKET_IN LIVE' \
+ 'packet-in NO_RECV LIVE' \
'up NO_RECV LIVE' \
- 'receive 0 LIVE'
+ 'receive 0 LIVE' \
+ 'down PORT_DOWN LINK_DOWN'
do
+ printf '\n--- %s --- \n\n' "$command_config_state"
set $command_config_state
command=$[1] config=`echo $[2] | sed 's/,/ /g'` state=$[3]
AT_CHECK([ovs-ofctl -O OpenFlow14 -vwarn mod-port br0 br0 $command])
@@ -1361,15 +1364,16 @@ AT_SETUP([ofproto - mod-port (OpenFlow 1.6)])
OVS_VSWITCHD_START
for command_config_state in \
'up 0 LIVE' \
- 'down PORT_DOWN LINK_DOWN' \
- 'no-receive PORT_DOWN,NO_RECV LINK_DOWN' \
- 'no-forward PORT_DOWN,NO_RECV,NO_FWD LINK_DOWN' \
- 'no-packet-in PORT_DOWN,NO_RECV,NO_FWD,NO_PACKET_IN LINK_DOWN' \
- 'forward PORT_DOWN,NO_RECV,NO_PACKET_IN LINK_DOWN' \
- 'packet-in PORT_DOWN,NO_RECV LINK_DOWN' \
+ 'no-receive NO_RECV LIVE' \
+ 'no-forward NO_RECV,NO_FWD LIVE' \
+ 'no-packet-in NO_RECV,NO_FWD,NO_PACKET_IN LIVE' \
+ 'forward NO_RECV,NO_PACKET_IN LIVE' \
+ 'packet-in NO_RECV LIVE' \
'up NO_RECV LIVE' \
- 'receive 0 LIVE'
+ 'receive 0 LIVE' \
+ 'down PORT_DOWN LINK_DOWN'
do
+ printf '\n--- %s --- \n\n' "$command_config_state"
set $command_config_state
command=$[1] config=`echo $[2] | sed 's/,/ /g'` state=$[3]
AT_CHECK([ovs-ofctl -O OpenFlow16 -vwarn mod-port br0 br0 $command])
@@ -3280,7 +3284,7 @@ OVS_VSWITCHD_STOP
AT_CLEANUP
AT_SETUP([ofproto - asynchronous message control (OpenFlow 1.0)])
-OVS_VSWITCHD_START
+OVS_VSWITCHD_START([set bridge br0 other_config:hwaddr=00:01:02:03:04:05])
AT_CHECK([ovs-ofctl -P standard monitor br0 --detach --no-chdir --pidfile])
check_async () {
printf '\n\n--- check_async %d ---\n\n\n' $1
@@ -3315,8 +3319,8 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl add-port br0 test -- set Interface test type=dummy ofport_request=1
if test X"$1" = X"OFPPR_ADD"; then shift;
echo >>expout "OFPT_PORT_STATUS: ADD: 1(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3324,8 +3328,8 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl del-port br0 test
if test X"$1" = X"OFPPR_DELETE"; then shift;
echo >>expout "OFPT_PORT_STATUS: DEL: 1(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3418,8 +3422,12 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl add-port br0 test -- set Interface test type=dummy
if test X"$1" = X"OFPPR_ADD"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.2): ADD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
+ speed: 0 Mbps now, 0 Mbps max
+OFPT_PORT_STATUS (OF1.2): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3427,8 +3435,8 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl del-port br0 test
if test X"$1" = X"OFPPR_DELETE"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.2): DEL: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3528,8 +3536,12 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl add-port br0 test -- set Interface test type=dummy
if test X"$1" = X"OFPPR_ADD"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.3): ADD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
+ speed: 0 Mbps now, 0 Mbps max
+OFPT_PORT_STATUS (OF1.3): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3537,8 +3549,8 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl del-port br0 test
if test X"$1" = X"OFPPR_DELETE"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.3): DEL: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3646,21 +3658,25 @@ udp,vlan_tci=0x0000,dl_src=00:26:b9:8c:b0:f9,dl_dst=00:25:83:df:b4:00,nw_src=172
ovs-vsctl add-port br0 test -- set Interface test type=dummy
if test X"$1" = X"OFPPR_ADD"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.4): ADD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
+ speed: 0 Mbps now, 0 Mbps max
+OFPT_PORT_STATUS (OF1.4): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
# OFPT_PORT_STATUS, OFPPR_MODIFY
- ovs-ofctl -O OpenFlow14 -vwarn mod-port br0 test up
+ ovs-ofctl -O OpenFlow14 -vwarn mod-port br0 test down
if test X"$1" = X"OFPPR_MODIFY"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.4): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LINK_DOWN
+ config: PORT_DOWN
+ state: 0
speed: 0 Mbps now, 0 Mbps max
OFPT_PORT_STATUS (OF1.4): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LIVE
+ config: PORT_DOWN
+ state: LINK_DOWN
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3668,8 +3684,8 @@ OFPT_PORT_STATUS (OF1.4): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
ovs-vsctl del-port br0 test
if test X"$1" = X"OFPPR_DELETE"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.4): DEL: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LIVE
+ config: PORT_DOWN
+ state: LINK_DOWN
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3827,21 +3843,25 @@ check_async () {
ovs-vsctl add-port br0 test -- set Interface test type=dummy
if test X"$1" = X"OFPPR_ADD"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.5): ADD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: PORT_DOWN
- state: LINK_DOWN
+ config: 0
+ state: 0
+ speed: 0 Mbps now, 0 Mbps max
+OFPT_PORT_STATUS (OF1.5): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
+ config: 0
+ state: LIVE
speed: 0 Mbps now, 0 Mbps max"
fi
# OFPT_PORT_STATUS, OFPPR_MODIFY
- ovs-ofctl -O OpenFlow15 -vwarn mod-port br0 test up
+ ovs-ofctl -O OpenFlow15 -vwarn mod-port br0 test down
if test X"$1" = X"OFPPR_MODIFY"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.5): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LINK_DOWN
+ config: PORT_DOWN
+ state: 0
speed: 0 Mbps now, 0 Mbps max
-OFPT_PORT_STATUS (OF1.5): MOD: 2(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LIVE
+OFPT_PORT_STATUS (OF1.5): MOD: ${INDEX}(test): addr:aa:55:aa:55:00:0x
+ config: PORT_DOWN
+ state: LINK_DOWN
speed: 0 Mbps now, 0 Mbps max"
fi
@@ -3849,8 +3869,8 @@ OFPT_PORT_STATUS (OF1.5): MOD: 2(test): addr:aa:55:aa:55:00:0x
ovs-vsctl del-port br0 test
if test X"$1" = X"OFPPR_DELETE"; then shift;
echo >>expout "OFPT_PORT_STATUS (OF1.5): DEL: ${INDEX}(test): addr:aa:55:aa:55:00:0x
- config: 0
- state: LIVE
+ config: PORT_DOWN
+ state: LINK_DOWN
speed: 0 Mbps now, 0 Mbps max"
fi
Dummy ports started out down and hardly any of the tests ever brought them up. This led to some odd test results and caused problems for testing with controllers that didn't bother with ports that were down, like recent versions of Faucet. There doesn't seem to be a big reason for them to be down by default, so this commit changes them to be up by default. It also updates the tests to match the new behavior. Reported-by: Brad Cowie <brad@cowie.nz> Reported-at: https://mail.openvswitch.org/pipermail/ovs-discuss/2018-August/047234.html Signed-off-by: Ben Pfaff <blp@ovn.org> --- lib/netdev-dummy.c | 2 +- tests/ofproto-dpif.at | 20 ++--- tests/ofproto.at | 206 +++++++++++++++++++++++++++----------------------- 3 files changed, 124 insertions(+), 104 deletions(-)