]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
i40e: update comment explaining where FDIR buffers are freed
authorJacob Keller <jacob.e.keller@intel.com>
Fri, 10 Feb 2017 07:44:27 +0000 (23:44 -0800)
committerJack Vogel <jack.vogel@oracle.com>
Sat, 10 Jun 2017 01:57:02 +0000 (18:57 -0700)
The original comment implies that the only location where the raw_packet
buffer will be freed is in i40e_clean_tx_ring() which is incorrect. In
fact this isn't even the normal case. Update the comment explaining
where the memory is freed.

Change-ID: Ie0defc35ed1c3af183f81fdc60b6d783707a5595
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Orabug: 26132523
(cherry picked from commit a158aeaf5bb5b014240b360693751476aca7440b)
Signed-off-by: Jack Vogel <jack.vogel@oracle.com>
Reviewed-by: Brian Maly <brian.maly@oracle.com>
drivers/net/ethernet/intel/i40e/i40e_txrx.c

index 5ecd6c76d130e6d5976a19778ab212eecbede888..51a175ffa77485a0d0224c976e2a42b16e143450 100644 (file)
@@ -433,7 +433,12 @@ unsupported_flow:
                ret = -EINVAL;
        }
 
-       /* The buffer allocated here is freed by the i40e_clean_tx_ring() */
+       /* The buffer allocated here will be normally be freed by
+        * i40e_clean_fdir_tx_irq() as it reclaims resources after transmit
+        * completion. In the event of an error adding the buffer to the FDIR
+        * ring, it will immediately be freed. It may also be freed by
+        * i40e_clean_tx_ring() when closing the VSI.
+        */
        return ret;
 }