git://git.onelab.eu
/
sliver-openvswitch.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
stream: Introduce [p]windows_[p]stream_class.
[sliver-openvswitch.git]
/
lib
/
ofp-version-opt.c
diff --git
a/lib/ofp-version-opt.c
b/lib/ofp-version-opt.c
index
1801e9f
..
10784fc
100644
(file)
--- a/
lib/ofp-version-opt.c
+++ b/
lib/ofp-version-opt.c
@@
-1,10
+1,8
@@
#include <config.h>
#include <config.h>
+#include "dynamic-string.h"
#include "ofp-util.h"
#include "ofp-version-opt.h"
#include "ofp-util.h"
#include "ofp-version-opt.h"
-#include "vlog.h"
-#include "dynamic-string.h"
-
-VLOG_DEFINE_THIS_MODULE(ofp_version);
+#include "ovs-thread.h"
static uint32_t allowed_versions = 0;
static uint32_t allowed_versions = 0;
@@
-17,9
+15,17
@@
get_allowed_ofp_versions(void)
void
set_allowed_ofp_versions(const char *string)
{
void
set_allowed_ofp_versions(const char *string)
{
+ assert_single_threaded();
allowed_versions = ofputil_versions_from_string(string);
}
allowed_versions = ofputil_versions_from_string(string);
}
+void
+mask_allowed_ofp_versions(uint32_t bitmap)
+{
+ assert_single_threaded();
+ allowed_versions &= bitmap;
+}
+
void
ofp_version_usage(void)
{
void
ofp_version_usage(void)
{
@@
-29,7
+35,7
@@
ofp_version_usage(void)
printf(
"\nOpen Flow Version options:\n"
" -V, --version display version information\n"
printf(
"\nOpen Flow Version options:\n"
" -V, --version display version information\n"
- " -
-allowed-ofp-versions list of
allowed Open Flow versions\n"
+ " -
O, --protocols set
allowed Open Flow versions\n"
" (default: %s)\n",
ds_cstr(&msg));
ds_destroy(&msg);
" (default: %s)\n",
ds_cstr(&msg));
ds_destroy(&msg);