[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240220150933.GP40273@kernel.org>
Date: Tue, 20 Feb 2024 15:09:33 +0000
From: Simon Horman <horms@...nel.org>
To: Jeremy Kerr <jk@...econstruct.com.au>
Cc: netdev@...r.kernel.org, Matt Johnston <matt@...econstruct.com.au>,
"David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>
Subject: Re: [PATCH net-next v2] net: mctp: take ownership of skb in
mctp_local_output
On Tue, Feb 20, 2024 at 04:10:53PM +0800, Jeremy Kerr wrote:
> Currently, mctp_local_output only takes ownership of skb on success, and
> we may leak an skb if mctp_local_output fails in specific states; the
> skb ownership isn't transferred until the actual output routing occurs.
>
> Instead, make mctp_local_output free the skb on all error paths up to
> the route action, so it always consumes the passed skb.
>
> Fixes: 833ef3b91de6 ("mctp: Populate socket implementation")
> Signed-off-by: Jeremy Kerr <jk@...econstruct.com.au>
>
> ---
> v2:
> - retain EINVAL return code in !rt && !ifindex case. Based on feedback
> from Simon Horman <horms@...nel.org>.
Hi Jeremy,
Thanks for the update.
This one looks good to me.
Reviewed-by: Simon Horman <horms@...nel.org>
Powered by blists - more mailing lists