]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
octeontx2-pf: Fix leak of SQ timestamp buffer on teardown
authorRatheesh Kannoth <rkannoth@marvell.com>
Mon, 15 Jun 2026 03:07:04 +0000 (08:37 +0530)
committerJakub Kicinski <kuba@kernel.org>
Wed, 17 Jun 2026 23:25:30 +0000 (16:25 -0700)
commita056db30de92945ff8ee6033096678bfbae878e3
tree93fa3e78cb9e725f16c12e310076c42dac54aebd
parent1f24c0d01db214c9e661915e9972404c96ca73c0
octeontx2-pf: Fix leak of SQ timestamp buffer on teardown

The send-queue timestamp ring is allocated with qmem_alloc() when
timestamping is used, but otx2_free_sq_res() never freed sq->timestamps,
leaking that memory across ifdown and device removal.  Add the missing
qmem_free() alongside the other SQ companion buffers.

Fixes: c9c12d339d93 ("octeontx2-pf: Add support for PTP clock")
Cc: Aleksey Makarov <amakarov@marvell.com>
Signed-off-by: Ratheesh Kannoth <rkannoth@marvell.com>
Reviewed-by: Simon Horman <horms@kernel.org>
Link: https://patch.msgid.link/20260615030704.504536-1-rkannoth@marvell.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/ethernet/marvell/octeontx2/nic/otx2_pf.c