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:	Thu, 12 May 2011 17:59:59 -0400 (EDT)
From:	David Miller <davem@...emloft.net>
To:	joe@...ches.com
Cc:	linux-kernel@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [PATCH] net: af_packet: Don't initialize vnet_hdr

From: Joe Perches <joe@...ches.com>
Date: Thu, 12 May 2011 14:55:48 -0700

> Save an initialization because when this structure
> is used it's completely filled by memcpy_fromiovec.
> 
> Add a new variable used for the 0 sized allocation
> when this structure is not used.
> 
> Signed-off-by: Joe Perches <joe@...ches.com>
> 
> ---
> 
> On Thu, 2011-05-12 at 17:36 -0400, David Miller wrote:
>> I would rather see the code rearranged such that this sort of
>> hackish scheme isn't necessary.

You misunderstood me.

It's this:

	struct virtio_net_hdr vnet_hdr;


	if (po->has_vnet_hdr) {
		initialize &vnet_hdr
	}

	...

	if (po->has_vnet_hdr) {
		use vnet_hdr
	}

which I'm talking about when I say "hackish scheme".

The compiler cannot conclusively see that the control flow always
goes to the code that initialized vnet_hdr every time it reaches
the code that uses it.

I want _that_ part rearranged, not what you decided to tackle
here.

For the third time, I'm not applying your patch.
--
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