lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 3 Nov 2009 09:07:52 -0800
From:	Stephen Hemminger <shemminger@...ux-foundation.org>
To:	Arnd Hannemann <hannemann@...s.rwth-aachen.de>
Cc:	"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
	Arnd Hannemann <Arnd.Hannemann@...s.rwth-aachen.de>
Subject: Re: [PATCH] iproute2: Avoid rounding errors for 100%.

On Tue, 03 Nov 2009 17:19:45 +0100
Arnd Hannemann <hannemann@...s.rwth-aachen.de> wrote:

> Although the patch makes sense,
> it does not fix the bug/effect we were seeing.
> A netem reorder percentage of 100% will still get packets reordered.
> (if the netem queue is not empty)
> 
> 
> hannemann@...s.rwth-aachen.de wrote:
> > From: Arnd Hannemann <hannemann@...s.rwth-aachen.de>
> > 
> > We noticed that a netem reorder percentage of 100% will still get packets reordered.
> > This patch fixes that.
> > 
> > Signed-off-by: Arnd Hannemann <hannemann@...s.rwth-aachen.de>
> > ---
> >  tc/tc_util.c |    6 ++++--
> >  1 files changed, 4 insertions(+), 2 deletions(-)
> > 
> > diff --git a/tc/tc_util.c b/tc/tc_util.c
> > index fe2c7eb..2641f2e 100644
> > --- a/tc/tc_util.c
> > +++ b/tc/tc_util.c
> > @@ -363,8 +363,10 @@ int get_percent(__u32 *percent, const char *str)
> >  		return -1;
> >  	if (*p && strcmp(p, "%"))
> >  		return -1;
> > -
> > -	*percent = (unsigned) rint(per * max_percent_value);
> > +	if (per == 1.)
> > +		*percent = max_percent_value;
> > +	else
> > +		*percent = (unsigned) rint(per * max_percent_value);
> >  	return 0;
> >  }
> >  
> 
> 

If you don't want reordering, don't specify reordering?


-- 
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ