summaryrefslogtreecommitdiff
path: root/lib/dp-packet.h
diff options
context:
space:
mode:
authorDavid Marchand <david.marchand@redhat.com>2022-08-25 12:25:24 +0200
committerIlya Maximets <i.maximets@ovn.org>2022-11-30 13:58:15 +0100
commit0937209fc7aca1107bb3f77cf1585799a086d065 (patch)
tree6c43905e85fe5de6f180f8e0e38bc7eec117c9a2 /lib/dp-packet.h
parent22413fe8a83cc4e153fc35defc6f01f7dc5a21b5 (diff)
downloadopenvswitch-0937209fc7aca1107bb3f77cf1585799a086d065.tar.gz
netdev-dpdk: Cleanup code when DPDK is disabled.
Remove one unused stub: netdev_dpdk_register() can't be called if DPDK is disabled at build time. Remove unneeded #ifdef in call to free_dpdk_buf. Drop unneeded cast when calling free_dpdk_buf. Acked-by: Sunil Pai G <sunil.pai.g@intel.com> Signed-off-by: David Marchand <david.marchand@redhat.com> Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
Diffstat (limited to 'lib/dp-packet.h')
-rw-r--r--lib/dp-packet.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/dp-packet.h b/lib/dp-packet.h
index 55eeaab2c..a8ea5b40f 100644
--- a/lib/dp-packet.h
+++ b/lib/dp-packet.h
@@ -247,9 +247,7 @@ dp_packet_delete(struct dp_packet *b)
{
if (b) {
if (b->source == DPBUF_DPDK) {
- /* If this dp_packet was allocated by DPDK it must have been
- * created as a dp_packet */
- free_dpdk_buf((struct dp_packet*) b);
+ free_dpdk_buf(b);
return;
}