From 0194e890b958c1cf947544909edb128549482b0f Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Thu, 19 Mar 2009 14:02:07 -0700 Subject: [PATCH] secchan: Remove ofproto hook functions that are no longer used. --- secchan/ofproto.c | 12 +----------- secchan/ofproto.h | 3 --- vswitchd/bridge.c | 2 -- 3 files changed, 1 insertion(+), 16 deletions(-) diff --git a/secchan/ofproto.c b/secchan/ofproto.c index 3ff45acd..e11eed2a 100644 --- a/secchan/ofproto.c +++ b/secchan/ofproto.c @@ -2766,16 +2766,8 @@ handle_odp_msg(struct ofproto *p, struct ofpbuf *packet) rule = lookup_valid_rule(p, &flow); if (!rule) { - struct ofport *port; - - if (p->ofhooks->packet_in_cb - && p->ofhooks->packet_in_cb(&flow, &payload, p->aux)) { - ofpbuf_delete(packet); - return; - } - /* Don't send a packet-in if OFPPC_NO_PACKET_IN asserted. */ - port = port_array_get(&p->ports, msg->port); + struct ofport *port = port_array_get(&p->ports, msg->port); if (port) { if (port->opp.config & OFPPC_NO_PACKET_IN) { /* XXX install 'drop' flow entry */ @@ -3154,8 +3146,6 @@ default_normal_ofhook_cb(const flow_t *flow, bool revalidating, } static const struct ofhooks default_ofhooks = { - NULL, - NULL, NULL, default_normal_ofhook_cb, }; diff --git a/secchan/ofproto.h b/secchan/ofproto.h index 4a16a3ca..a90f23f8 100644 --- a/secchan/ofproto.h +++ b/secchan/ofproto.h @@ -112,9 +112,6 @@ void ofproto_flush_flows(struct ofproto *); struct ofhooks { void (*port_changed_cb)(enum ofp_port_reason, const struct ofp_phy_port *, void *aux); - bool (*packet_in_cb)(const flow_t *, const struct ofpbuf *payload, - void *aux); - void (*flow_expired_cb)(const struct ofexpired *, void *aux); void (*normal_cb)(const flow_t *, bool revalidating, struct odp_actions *, tag_type *, void *aux); }; diff --git a/vswitchd/bridge.c b/vswitchd/bridge.c index 4567e66d..0248c8dd 100644 --- a/vswitchd/bridge.c +++ b/vswitchd/bridge.c @@ -1661,8 +1661,6 @@ bridge_normal_ofhook_cb(const flow_t *flow, bool revalidating, static struct ofhooks bridge_ofhooks = { bridge_port_changed_ofhook_cb, - NULL, - NULL, bridge_normal_ofhook_cb, }; -- 2.30.2