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 PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Mon, 5 May 2014 11:47:02 -0300 From: Ezequiel Garcia <ezequiel.garcia@...e-electrons.com> To: netdev@...r.kernel.org Cc: "David S. Miller" <davem@...emloft.net>, Eric Dumazet <eric.dumazet@...il.com>, cmetcalf@...era.com, Thomas Petazzoni <thomas.petazzoni@...e-electrons.com>, Gregory Clement <gregory.clement@...e-electrons.com>, Simon Guinot <simon.guinot@...uanux.org>, Willy Tarreau <w@....eu>, Tawfik Bayouk <tawfik@...vell.com>, Lior Amsalem <alior@...vell.com>, Simon Guinot <sguinot@...ie.com> Subject: Re: [PATCH 3/3] net: mvneta: Introduce a software TSO implementation Hi all, On 10 Apr 07:58 PM, Ezequiel Garcia wrote: [..] > + > + /* Calculate expected number of TX descriptors */ > + desc_count = skb_shinfo(skb)->gso_segs * 2 + skb_shinfo(skb)->nr_frags; > + if ((txq->count + desc_count) >= txq->size) > + return 0; > + Is this calculus correct? Does it give the accurate number of needed descriptors or is it an approximation? Tilera's tilegx driver does a much stricter descriptor count (see tso_count_edescs). This functions loops through the skb_frag_t fragments as it's done later in the data egress, hence strictly counting the needed descriptors. However, as it's a much heavier routine than the one shown above, I'm wondering if we can get away without it. Willy, Any ideas here? -- Ezequiel GarcĂa, Free Electrons Embedded Linux, Kernel and Android Engineering http://free-electrons.com -- 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