From: Alexandru Copot Date: Thu, 1 May 2014 10:22:20 +0000 (+0300) Subject: ofp-print: Enable printing OF1.4 version X-Git-Tag: sliver-openvswitch-2.2.90-1~3^2~20 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;ds=inline;h=9620f50ccce53b75c45949f3984029fa67241afe;p=sliver-openvswitch.git ofp-print: Enable printing OF1.4 version Also fix some tests that can now properly print packets with the new protocol version. Signed-off-by: Alexandru Copot Cc: Daniel Baluta Signed-off-by: Ben Pfaff --- diff --git a/lib/ofp-print.c b/lib/ofp-print.c index 9091b1bf5..38e228c9d 100644 --- a/lib/ofp-print.c +++ b/lib/ofp-print.c @@ -2295,6 +2295,9 @@ ofp_print_version(const struct ofp_header *oh, case OFP13_VERSION: ds_put_cstr(string, " (OF1.3)"); break; + case OFP14_VERSION: + ds_put_cstr(string, " (OF1.4)"); + break; default: ds_put_format(string, " (OF 0x%02"PRIx8")", oh->version); break; diff --git a/tests/ofp-print.at b/tests/ofp-print.at index ef3102fa4..b74b681a7 100644 --- a/tests/ofp-print.at +++ b/tests/ofp-print.at @@ -2375,7 +2375,7 @@ AT_CHECK([ovs-ofctl ofp-print "\ 05 1e 00 18 00 00 00 0a \ 00 00 00 02 02 00 00 00 ff ff ff ff ff ff ff ff \ "], [0], [dnl -OFPT_ROLE_STATUS (OF 0x05) (xid=0xa): role=master reason=experimenter_data_changed +OFPT_ROLE_STATUS (OF1.4) (xid=0xa): role=master reason=experimenter_data_changed ]) AT_CLEANUP @@ -2385,7 +2385,7 @@ AT_CHECK([ovs-ofctl ofp-print "\ 05 1e 00 18 00 00 00 0a \ 00 00 00 02 01 00 00 00 ff ff ff ff ff ff ff ff \ "], [0], [dnl -OFPT_ROLE_STATUS (OF 0x05) (xid=0xa): role=master reason=configuration_changed +OFPT_ROLE_STATUS (OF1.4) (xid=0xa): role=master reason=configuration_changed ]) AT_CLEANUP @@ -2395,7 +2395,7 @@ AT_CHECK([ovs-ofctl ofp-print "\ 05 1e 00 18 00 00 00 0a \ 00 00 00 02 01 00 00 00 00 00 00 00 00 00 00 10 \ "], [0], [dnl -OFPT_ROLE_STATUS (OF 0x05) (xid=0xa): role=master generation_id=16 reason=configuration_changed +OFPT_ROLE_STATUS (OF1.4) (xid=0xa): role=master generation_id=16 reason=configuration_changed ]) AT_CLEANUP diff --git a/tests/ofp-util.at b/tests/ofp-util.at index fbb6848f3..248faf419 100644 --- a/tests/ofp-util.at +++ b/tests/ofp-util.at @@ -24,7 +24,7 @@ OFPT_HELLO (OF1.3) (xid=0x1): ]) AT_CHECK([ovs-ofctl encode-hello 0x3e], [0], [dnl 00000000 05 00 00 08 00 00 00 01- -OFPT_HELLO (OF 0x05) (xid=0x1): +OFPT_HELLO (OF1.4) (xid=0x1): version bitmap: 0x01, 0x02, 0x03, 0x04, 0x05 ])