[ovs-dev] [PATCH 1/2] datapath: Add loop checking.

Ben Pfaff blp at nicira.com
Tue Jul 13 18:32:46 UTC 2010


On Mon, Jul 12, 2010 at 02:31:16PM -0700, Jesse Gross wrote:
> New types of vports such as patch and GRE make it possible to
> connect multiple (or the same) datapaths together, which introduces
> the possibility of loops on a single machine.  Local loops are
> even worse than network loops because they will quickly crash the
> machine once the kernel stack is exhausted.  This adds loop
> checking within the OVS datapath that will drop packets that have
> been seen more than 5 times.

I'd be tempted to use local atomic operations (see
Documentation/local_ops.txt) instead of separate interrupt and
non-interrupt counters to maintain the counts.  They seem tailor-made
for the purpose.  Did you consider them?

Have you done any kind of analysis or reasoning to figure out the amount
of stack required by 5-deep recursion?




More information about the dev mailing list