DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/2] net/ice: fix memory handling issues
@ 2026-10-07  7:58 Anurag Mandal
  2026-10-07  7:58 ` [PATCH 1/2] net/ice: free memory with matching allocator Anurag Mandal
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Anurag Mandal @ 2026-10-07  7:58 UTC (permalink / raw)
  To: dev; +Cc: bruce.richardson, anatoly.burakov, Anurag Mandal

This patch series addresses two memory handling issues in the ice PMD.

- The first one makes memory allocation and release symmetric. 
  Several buffers obtained through ice_malloc(), ice_calloc() 
  or ice_memdup() were released with rte_free() instead of ice_free(). 
  Both APIs currently map to the same underlying allocator. 
  However, mixing them is inconsistent and would break if the OS 
  abstraction layer ever changes.

- The second one fixes an unchecked allocation in ice_tx_queue_start() 
  which dereferences the Tx time queue context buffer returned by 
  ice_malloc() without NULL check.
  On allocation failure, the E830 send-on-timestamp path therefore crashes
  instead of reporting "No Memory" error, and also the already allocated
  txq_elem buffer gets leaked.

Anurag Mandal (2):
  net/ice: free memory with matching allocator
  net/ice: fix unchecked Tx time context allocation

 drivers/net/intel/ice/ice_acl_filter.c  | 10 +++++-----
 drivers/net/intel/ice/ice_dcf.c         |  2 +-
 drivers/net/intel/ice/ice_dcf_parent.c  |  2 +-
 drivers/net/intel/ice/ice_ethdev.c      | 14 +++++++-------
 drivers/net/intel/ice/ice_fdir_filter.c | 12 ++++++------
 drivers/net/intel/ice/ice_rxtx.c        | 22 +++++++++++++---------
 6 files changed, 33 insertions(+), 29 deletions(-)

-- 
2.34.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2026-10-07  9:31 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-07  7:58 [PATCH 0/2] net/ice: fix memory handling issues Anurag Mandal
2026-10-07  7:58 ` [PATCH 1/2] net/ice: free memory with matching allocator Anurag Mandal
2026-10-07  8:04   ` Bruce Richardson
2026-10-07  7:58 ` [PATCH 2/2] net/ice: fix unchecked Tx time context allocation Anurag Mandal
2026-10-07  9:31 ` [PATCH 0/2] net/ice: fix memory handling issues Bruce Richardson

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox