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] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 30 Nov 2007 20:59:48 +1100
From:	Herbert Xu <herbert@...dor.apana.org.au>
To:	gallatin@...i.com (Andrew Gallatin)
Cc:	davem@...emloft.net, ossthema@...ibm.com, netdev@...r.kernel.org
Subject: Re: [PATCH]: fix lro_gen_skb() alignment

Andrew Gallatin <gallatin@...i.com> wrote:
>
> diff --git a/net/ipv4/inet_lro.c b/net/ipv4/inet_lro.c
> index ac3b1d3..91e9371 100644
> --- a/net/ipv4/inet_lro.c
> +++ b/net/ipv4/inet_lro.c
> @@ -401,10 +401,11 @@ static struct sk_buff *lro_gen_skb(struc
>        int data_len = len;
>        int hdr_len = min(len, hlen);
> 
> -       skb = netdev_alloc_skb(lro_mgr->dev, hlen);
> +       skb = netdev_alloc_skb(lro_mgr->dev, hlen + NET_IP_ALIGN);

NET_IP_ALIGN should only be used if you're DMAing into the skb head.
Otherwise you should say 2.  It would be nice to have another macro
for that I suppose.

Cheers,
-- 
Visit Openswan at http://www.openswan.org/
Email: Herbert Xu ~{PmV>HI~} <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
-
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