On 12/22/16 at 10:33P, Gleb Smirnoff wrote:
> Hi!
>
> On Wed, Dec 21, 2016 at 04:19:28PM -0800, hiren panchasara wrote:
> h> On 12/09/16 at 05:58P, Gleb Smirnoff wrote:
> h> > Author: glebius
> h> > Date: Fri Dec 9 17:58:34 2016
> h> > New Revision: 309745
> h> > URL: https://svnweb.freebsd.org
Hi!
On Wed, Dec 21, 2016 at 04:19:28PM -0800, hiren panchasara wrote:
h> On 12/09/16 at 05:58P, Gleb Smirnoff wrote:
h> > Author: glebius
h> > Date: Fri Dec 9 17:58:34 2016
h> > New Revision: 309745
h> > URL: https://svnweb.freebsd.org/changeset/base/309745
h> >
h> > Log:
h> > Provide counte
On 12/09/16 at 05:58P, Gleb Smirnoff wrote:
> Author: glebius
> Date: Fri Dec 9 17:58:34 2016
> New Revision: 309745
> URL: https://svnweb.freebsd.org/changeset/base/309745
>
> Log:
> Provide counter_ratecheck(), a MP-friendly substitution to ppsratecheck().
> When rated event happens at a ve
On Fri, Dec 09, 2016 at 10:56:36AM -0800, Gleb Smirnoff wrote:
> Yes, this is expected. The interface isn't designed to be precise. So if
> we hit limit, the next second result will be 20345 events exceeded the rate
> instead of 20346 events.
Note that the interface may legitimately give errors in
Konstantin,
On Fri, Dec 09, 2016 at 08:41:17PM +0200, Konstantin Belousov wrote:
K> > +int64_t
K> > +counter_ratecheck(struct counter_rate *cr, int64_t limit)
K> > +{
K> > + int64_t val;
K> > + int now;
K> > +
K> > + val = cr->cr_over;
K> > + now = ticks;
K> > +
K> > + if (now - cr->cr_tick
On Fri, Dec 09, 2016 at 05:58:34PM +, Gleb Smirnoff wrote:
> Author: glebius
> Date: Fri Dec 9 17:58:34 2016
> New Revision: 309745
> URL: https://svnweb.freebsd.org/changeset/base/309745
>
> Log:
> Provide counter_ratecheck(), a MP-friendly substitution to ppsratecheck().
> When rated ev