[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <40412731-cb3f-65e4-178d-8cb0dbf335d8@iogearbox.net>
Date: Wed, 19 Dec 2018 22:04:58 +0100
From: Daniel Borkmann <daniel@...earbox.net>
To: bjorn.topel@...il.com, ast@...nel.org, netdev@...r.kernel.org
Cc: Björn Töpel <bjorn.topel@...el.com>,
magnus.karlsson@...el.com, magnus.karlsson@...il.com
Subject: Re: [PATCH bpf-next] xsk: simplify AF_XDP socket teardown
On 12/19/2018 01:09 PM, bjorn.topel@...il.com wrote:
> From: Björn Töpel <bjorn.topel@...el.com>
>
> Prior this commit, when the struct socket object was being released,
> the UMEM did not have its reference count decreased. Instead, this was
> done in the struct sock sk_destruct function.
>
> There is no reason to keep the UMEM reference around when the socket
> is being orphaned, so in this patch the xdp_put_mem is called in the
> xsk_release function. This results in that the xsk_destruct function
> can be removed!
>
> Note that, it still holds that a struct xsk_sock reference might still
> linger in the XSKMAP after the UMEM is released, e.g. if a user does
> not clear the XSKMAP prior to closing the process. This sock will be
> in a "released" zombie like state, until the XSKMAP is removed.
>
> Signed-off-by: Björn Töpel <bjorn.topel@...el.com>
Applied, thanks!
Powered by blists - more mailing lists