[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <edbb568c-c38a-0f72-e3de-e5922fa21c05@gmail.com>
Date: Tue, 20 Mar 2018 17:11:19 +0000
From: David Lebrun <dav.lebrun@...il.com>
To: Eric Dumazet <eric.dumazet@...il.com>, netdev@...r.kernel.org
Cc: David Lebrun <dlebrun@...gle.com>,
Roopa Prabhu <roopa@...ulusnetworks.com>
Subject: Re: [PATCH net] ipv6: sr: fix scheduling in RCU when creating seg6
lwtunnel state
On 20/03/18 15:07, Eric Dumazet wrote:
> This is not the proper fix.
>
> Control path holds RTNL and can sleeep if needed.
>
> RCU should be avoided in lwtunnel_build_state()
>
+Roopa
In lwtunnel_build_state(), the RCU protects the lwtunnel_encap_ops "ops"
which is rcu-dereferenced. Moreover, the lwtunnel_state_alloc()
function, which is used in all build_state functions, also uses
GFP_ATOMIC, so this seemed a proper fix, or at least proper mitigation.
Do you suggest that the lwtunnel_encap_ops can be protected in a
different way, not requiring RCU ?
Powered by blists - more mailing lists