From: Hannes Frederic Sowa <hannes@stressinduktion.org>
To: pravin shelar <pshelar@ovn.org>
Cc: Linux Kernel Network Developers <netdev@vger.kernel.org>,
"David S. Miller" <davem@davemloft.net>,
Eric Dumazet <edumazet@google.com>
Subject: Re: [PATCH net] net: reduce RECURSION_LIMIT to 8
Date: Mon, 11 Jan 2016 13:24:15 +0100 [thread overview]
Message-ID: <56939EEF.70403@stressinduktion.org> (raw)
In-Reply-To: <CAOrHB_AWdZw1XDmxVU=bDh=gB2M3cnXUC8MyXCnV1YVjZEAsKw@mail.gmail.com>
On 11.01.2016 07:38, pravin shelar wrote:
> On Thu, Jan 7, 2016 at 9:40 AM, Hannes Frederic Sowa
> <hannes@stressinduktion.org> wrote:
>> When RECURSION_LIMIT was first introduced, Eric proposed a limit of 3.
>> This limit was later raised to 10 by DaveM. Nowadays it is observed that
>> configuraion errors in openvswitch cause the STACK_END_MAGIC to be
>> overwritten shortly after 9 recursion.
>>
> Major user of stack space in OVS is sw_flow_key in
> ovs_vport_receive(). With recent features like IPv6 tunnel support we
> have increased the size of the flow-key which could have caused the
> stack overflow sooner.
> One way to avoid using stack in subsequent recursive call is to use
> per-cpu storage for the sw_flow_key object. This is already done for
> OVS recursive actions, so we can expand on that facility.
Hmmm. This already came up. I think the difficulty is that
ovs_vport_receive can be called from actions again with skb_cloned skb
before the original's skb callstack is actually finished. Data in the
percpu area would be overwritten while still being used. It would need
some more logic IMHO.
What are recursive actions in ovs? I couldn't find any use of pcpu data
in there? Thanks! :)
We could as an intermediate step add a recursion counter to openvswitch
and limit call chains to depth 5, what do you think?
Bye,
Hannes
next prev parent reply other threads:[~2016-01-11 12:24 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-01-07 17:40 [PATCH net] net: reduce RECURSION_LIMIT to 8 Hannes Frederic Sowa
2016-01-10 22:59 ` David Miller
2016-01-11 6:38 ` pravin shelar
2016-01-11 12:24 ` Hannes Frederic Sowa [this message]
2016-01-12 0:36 ` pravin shelar
2016-01-12 1:48 ` Hannes Frederic Sowa
2016-01-12 20:41 ` pravin shelar
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56939EEF.70403@stressinduktion.org \
--to=hannes@stressinduktion.org \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=netdev@vger.kernel.org \
--cc=pshelar@ovn.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.