Re: [PATCH] net: refactor icmp_global_allow to improve readability and performance.

2016-01-01 Thread Mike Danese
Yes, I completely missed the purpose of that. As a new year's resolution, I resolve to read the comments. Thanks for the review! On Fri, Jan 1, 2016 at 3:07 PM, Eric Dumazet wrote: > On Thu, 2015-12-31 at 23:58 -0800, Mike Danese wrote: >> We can reduce the number of operations performed by icmp

Re: [PATCH] net: refactor icmp_global_allow to improve readability and performance.

2016-01-01 Thread Eric Dumazet
On Thu, 2015-12-31 at 23:58 -0800, Mike Danese wrote: > We can reduce the number of operations performed by icmp_global_allow > and make the routine more readable by refactoring it in two ways: > > First, this patch refactors the meaning of the "delta" variable. Before > this change, it meant min(

[PATCH] net: refactor icmp_global_allow to improve readability and performance.

2015-12-31 Thread Mike Danese
We can reduce the number of operations performed by icmp_global_allow and make the routine more readable by refactoring it in two ways: First, this patch refactors the meaning of the "delta" variable. Before this change, it meant min("time since last refill of token bucket", HZ). After this change