mirror of
https://github.com/openvswitch/ovs
synced 2025-08-22 01:51:26 +00:00
ofproto-dpif-monitor: Remove unneeded calls to clear packets.
Currently the monitor will call dp_packet_clear() on the dp_packet that is shared amongst BFD, LLDP, and CFM. However, all of these packets are created with eth_compose(), which already calls dp_packet_clear(). Reviewed-by: David Marchand <david.marchand@redhat.com> Signed-off-by: Mike Pattrick <mkp@redhat.com> Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
This commit is contained in:
parent
8cebf7efba
commit
0061a48920
@ -275,19 +275,16 @@ monitor_mport_run(struct mport *mport, struct dp_packet *packet)
|
||||
long long int lldp_wake_time = LLONG_MAX;
|
||||
|
||||
if (mport->cfm && cfm_should_send_ccm(mport->cfm)) {
|
||||
dp_packet_clear(packet);
|
||||
cfm_compose_ccm(mport->cfm, packet, mport->hw_addr);
|
||||
ofproto_dpif_send_packet(mport->ofport, false, packet);
|
||||
}
|
||||
if (mport->bfd && bfd_should_send_packet(mport->bfd)) {
|
||||
bool oam;
|
||||
|
||||
dp_packet_clear(packet);
|
||||
bfd_put_packet(mport->bfd, packet, mport->hw_addr, &oam);
|
||||
ofproto_dpif_send_packet(mport->ofport, oam, packet);
|
||||
}
|
||||
if (mport->lldp && lldp_should_send_packet(mport->lldp)) {
|
||||
dp_packet_clear(packet);
|
||||
lldp_put_packet(mport->lldp, packet, mport->hw_addr);
|
||||
ofproto_dpif_send_packet(mport->ofport, false, packet);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user