lkml.org 
[lkml]   [2022]   [May]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [EXT] [PATCH 1/2] octeon_ep: Fix a memory leak in the error handling path of octep_request_irqs()
Date
> -----Original Message-----
> From: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> Sent: Sunday, May 15, 2022 8:57 AM
> To: Veerasenareddy Burru <vburru@marvell.com>; Abhijit Ayarekar
> <aayarekar@marvell.com>; David S. Miller <davem@davemloft.net>; Eric
> Dumazet <edumazet@google.com>; Jakub Kicinski <kuba@kernel.org>;
> Paolo Abeni <pabeni@redhat.com>; Satananda Burla <sburla@marvell.com>
> Cc: linux-kernel@vger.kernel.org; kernel-janitors@vger.kernel.org;
> Christophe JAILLET <christophe.jaillet@wanadoo.fr>;
> netdev@vger.kernel.org
> Subject: [EXT] [PATCH 1/2] octeon_ep: Fix a memory leak in the error
> handling path of octep_request_irqs()
>
> External Email
>
> ----------------------------------------------------------------------
> 'oct->non_ioq_irq_names' is not freed in the error handling path of
> octep_request_irqs().
>
> Add the missing kfree().
>
> Fixes: 37d79d059606 ("octeon_ep: add Tx/Rx processing and interrupt
> support")
> Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
> ---
> drivers/net/ethernet/marvell/octeon_ep/octep_main.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
> b/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
> index e020c81f3455..6b60a03574a0 100644
> --- a/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
> +++ b/drivers/net/ethernet/marvell/octeon_ep/octep_main.c
> @@ -267,6 +267,8 @@ static int octep_request_irqs(struct octep_device
> *oct)
> --i;
> free_irq(oct->msix_entries[i].vector, oct);
> }
> + kfree(oct->non_ioq_irq_names);
> + oct->non_ioq_irq_names = NULL;
Ack
Thanks for the change.

Regards,
Veerasenareddy
> alloc_err:
> return -1;
> }
> --
> 2.34.1

\
 
 \ /
  Last update: 2022-05-17 00:08    [W:0.186 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site