2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-29 15:28:56 +00:00
Files
openvswitch/lib/ofp-version-opt.h
Ben Pfaff 0d71302e36 ofp-util, ofp-parse: Break up into many separate modules.
ofp-util had been far too large and monolithic for a long time.  This
commit breaks it up into units that make some logical sense.  It also
moves the pieces of ofp-parse that were specific to each unit into the
relevant unit.

Most of this commit is just moving code around.

Signed-off-by: Ben Pfaff <blp@ovn.org>
Reviewed-by: Yifeng Sun <pkusunyifeng@gmail.com>
2018-02-13 10:43:13 -08:00

27 lines
984 B
C

#ifndef OFP_VERSION_H
#define OFP_VERSION_H 1
#include <openflow/openflow-common.h>
#include "util.h"
#define OFP_VERSION_LONG_OPTIONS \
{"version", no_argument, NULL, 'V'}, \
{"protocols", required_argument, NULL, 'O'}
#define OFP_VERSION_OPTION_HANDLERS \
case 'V': \
ovs_print_version(OFP10_VERSION, OFP14_VERSION); \
exit(EXIT_SUCCESS); \
\
case 'O': \
set_allowed_ofp_versions(optarg); \
break;
uint32_t get_allowed_ofp_versions(void);
void set_allowed_ofp_versions(const char *string);
void mask_allowed_ofp_versions(uint32_t);
void add_allowed_ofp_versions(uint32_t);
void ofp_version_usage(void);
#endif