projects
/
openvswitch
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
ovsdb-idl: Fix atomicity of writes that don't change a column's value.
[openvswitch]
/
ofproto
/
ofproto.c
diff --git
a/ofproto/ofproto.c
b/ofproto/ofproto.c
index 8b8b28dd13ee17a774a6eec47012d1baeb7727af..1865277136e2294bed068a0ad031f9c1520549e4 100644
(file)
--- a/
ofproto/ofproto.c
+++ b/
ofproto/ofproto.c
@@
-57,7
+57,6
@@
#include "shash.h"
#include "sset.h"
#include "stream-ssl.h"
#include "shash.h"
#include "sset.h"
#include "stream-ssl.h"
-#include "svec.h"
#include "tag.h"
#include "timer.h"
#include "timeval.h"
#include "tag.h"
#include "timer.h"
#include "timeval.h"
@@
-544,7
+543,7
@@
ofproto_set_desc(struct ofproto *p,
}
int
}
int
-ofproto_set_snoops(struct ofproto *ofproto, const struct s
vec
*snoops)
+ofproto_set_snoops(struct ofproto *ofproto, const struct s
set
*snoops)
{
return connmgr_set_snoops(ofproto->connmgr, snoops);
}
{
return connmgr_set_snoops(ofproto->connmgr, snoops);
}
@@
-553,7
+552,7
@@
int
ofproto_set_netflow(struct ofproto *ofproto,
const struct netflow_options *nf_options)
{
ofproto_set_netflow(struct ofproto *ofproto,
const struct netflow_options *nf_options)
{
- if (nf_options &&
nf_options->collectors.n
) {
+ if (nf_options &&
!sset_is_empty(&nf_options->collectors)
) {
if (!ofproto->netflow) {
ofproto->netflow = netflow_create();
}
if (!ofproto->netflow) {
ofproto->netflow = netflow_create();
}
@@
-668,8
+667,14
@@
ofproto_get_fail_mode(const struct ofproto *p)
return connmgr_get_fail_mode(p->connmgr);
}
return connmgr_get_fail_mode(p->connmgr);
}
+bool
+ofproto_has_snoops(const struct ofproto *ofproto)
+{
+ return connmgr_has_snoops(ofproto->connmgr);
+}
+
void
void
-ofproto_get_snoops(const struct ofproto *ofproto, struct s
vec
*snoops)
+ofproto_get_snoops(const struct ofproto *ofproto, struct s
set
*snoops)
{
connmgr_get_snoops(ofproto->connmgr, snoops);
}
{
connmgr_get_snoops(ofproto->connmgr, snoops);
}
@@
-1159,8
+1164,8
@@
ofport_run(struct ofproto *ofproto, struct ofport *ofport)
struct ccm *ccm;
ofpbuf_init(&packet, 0);
struct ccm *ccm;
ofpbuf_init(&packet, 0);
- ccm =
compose_packet
(&packet, eth_addr_ccm, ofport->opp.hw_addr,
-
ETH_TYPE_CFM, sizeof *ccm);
+ ccm =
eth_compose
(&packet, eth_addr_ccm, ofport->opp.hw_addr,
+ ETH_TYPE_CFM, sizeof *ccm);
cfm_compose_ccm(ofport->cfm, ccm);
ofproto_send_packet(ofproto, ofport->odp_port, 0, &packet);
ofpbuf_uninit(&packet);
cfm_compose_ccm(ofport->cfm, ccm);
ofproto_send_packet(ofproto, ofport->odp_port, 0, &packet);
ofpbuf_uninit(&packet);