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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1295301852.3362.16.camel@edumazet-laptop>
Date:	Mon, 17 Jan 2011 23:04:12 +0100
From:	Eric Dumazet <eric.dumazet@...il.com>
To:	Jesper Dangaard Brouer <hawk@...u.dk>
Cc:	Stephen Hemminger <shemminger@...tta.com>,
	Changli Gao <xiaosuo@...il.com>,
	David Miller <davem@...emloft.net>,
	Fabio Checconi <fabio@...dalf.sssup.it>,
	netdev <netdev@...r.kernel.org>,
	Luigi Rizzo <rizzo@....unipi.it>, hawk@...x.dk
Subject: Re: [PATCH] net_sched: factorize qdisc stats handling

Le lundi 17 janvier 2011 à 22:55 +0100, Jesper Dangaard Brouer a écrit :
> 
> On Sat, 8 Jan 2011, Eric Dumazet wrote:
> >> Changli Gao <xiaosuo@...il.com> wrote:
> >>
> >>>> +       cl->bstats.packets += skb_is_gso(skb)?skb_shinfo(skb)->gso_segs:1;
> 
> What about the qlen when we enqueue a GSO packet? Should we account for 
> the number of internal GSO packets, or just account a GSO packet as a 
> single packet?
> 
> diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
> index 0918834..1a8c0a3 100644
> --- a/net/sched/sch_generic.c
> +++ b/net/sched/sch_generic.c
> @@ -453,7 +453,8 @@ static int pfifo_fast_enqueue(struct sk_buff *skb, 
> struct Qdisc* qdisc)
>                  struct sk_buff_head *list = band2list(priv, band);
> 
>                  priv->bitmap |= (1 << band);
> -               qdisc->q.qlen++;
> +               /* Should the number of GSO packets be taken into account?*/
> +               qdisc->q.qlen += skb_is_gso(skb)?skb_shinfo(skb)->gso_segs:1;
>                  return __qdisc_enqueue_tail(skb, qdisc, list);
>          }
> 
> Is is at all legal to modify the q.qlen this way?

nope ;)

q.qlen is really number of skbs here.



--
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