net/enic: fix assignment
authorAaron Conole <aconole@redhat.com>
Tue, 26 Sep 2017 18:53:27 +0000 (14:53 -0400)
committerFerruh Yigit <ferruh.yigit@intel.com>
Thu, 12 Oct 2017 00:52:49 +0000 (01:52 +0100)
As it stands, the existing assignment to mbuf has no effect outside of
the function.  Prior to this change, the mbuf argument would contain
an invalid address, but it would not be null.  After this change, the
caller gets a null mbuf back.

Fixes: 947d860c821f ("enic: improve Rx performance")
Cc: stable@dpdk.org
Signed-off-by: Aaron Conole <aconole@redhat.com>
Reviewed-by: John Daley <johndale@cisco.com>
drivers/net/enic/enic_main.c

index 9b0439b..cac8b66 100644 (file)
@@ -224,7 +224,7 @@ enic_free_rq_buf(struct rte_mbuf **mbuf)
                return;
 
        rte_pktmbuf_free(*mbuf);
-       mbuf = NULL;
+       *mbuf = NULL;
 }
 
 void enic_init_vnic_resources(struct enic *enic)