}
return false;
}
-
-/* Sends 'packet' to each controller connected to 'mgr'. Takes ownership of
- * 'packet'. */
-void
-connmgr_broadcast(struct connmgr *mgr, struct ofpbuf *packet)
-{
- struct ofconn *ofconn, *prev;
-
- prev = NULL;
- LIST_FOR_EACH (ofconn, node, &mgr->all_conns) {
- if (prev) {
- ofconn_send_reply(ofconn, ofpbuf_clone(packet));
- }
- if (rconn_is_connected(ofconn->rconn)) {
- prev = ofconn;
- }
- }
- if (prev) {
- ofconn_send_reply(prev, packet);
- } else {
- ofpbuf_delete(packet);
- }
-}
\f
/* In-band configuration. */
bool connmgr_is_any_controller_connected(const struct connmgr *);
bool connmgr_is_any_controller_admitted(const struct connmgr *);
int connmgr_failure_duration(const struct connmgr *);
-void connmgr_broadcast(struct connmgr *, struct ofpbuf *);
/* In-band configuration. */
void connmgr_set_extra_in_band_remotes(struct connmgr *,