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
| ||
|
Date: Tue, 05 Jun 2012 04:50:31 +0200 From: Eric Dumazet <eric.dumazet@...il.com> To: "Michael S. Tsirkin" <mst@...hat.com> Cc: Willy Tarreau <w@....eu>, David Miller <davem@...emloft.net>, netdev@...r.kernel.org Subject: Re: [PATCH net-next] net: netdev_alloc_skb() use build_skb() On Tue, 2012-06-05 at 00:20 +0300, Michael S. Tsirkin wrote: > On Mon, Jun 04, 2012 at 09:56:52PM +0200, Eric Dumazet wrote: > > On Mon, 2012-06-04 at 22:48 +0300, Michael S. Tsirkin wrote: > > > > > If I do this what will truesize be? 128, no? > > > > My example was not correct, since you must have enough room for the > > SKB_DATA_ALIGN(sizeof(struct skb_shared_info)) ( 320 bytes ) > > > > So it would be 128 + 320 = 448 > > > > > Ugh. I forgot about that. shinfo goes into the same page, > so we'll have to also make all frags shorter by 320 > to leave space for shinfo at tail. > overall looks like we need hyprevisor extensions if > we want to use build_skb ... Maybe not. If you provided a 2048 bytes block and hypervisor filled one (small) frame, there might be available room at the end of the block for the shinfo already. If yes : You can use build_skb() If not : netdev_alloc_skb_ip_align() I mentioned this trick for ixgbe driver. -- 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