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]
Message-ID: <1369856073.1971.2.camel@bwh-desktop.uk.level5networks.com>
Date:	Wed, 29 May 2013 20:34:33 +0100
From:	Ben Hutchings <bhutchings@...arflare.com>
To:	David Miller <davem@...emloft.net>
CC:	<amwang@...hat.com>, <netdev@...r.kernel.org>, <horms@...ge.net.au>
Subject: Re: [Patch net-next] net: clean up skb headers code

On Tue, 2013-05-28 at 23:36 -0700, David Miller wrote:
> From: Cong Wang <amwang@...hat.com>
> Date: Wed, 29 May 2013 14:09:00 +0800
> 
> > commit 1a37e412a0225fcba5587 (net: Use 16bits for *_headers
> > fields of struct skbuff) converts skb->*_header to u16,
> > therefore 1) we could just use 0xFFFFF instead of (__u16) ~0U
> > 2) some #if NET_SKBUFF_DATA_USES_OFFSET is useless now.
> > 
> > 
> > Cc: David S. Miller <davem@...emloft.net>
> > Cc: Simon Horman <horms@...ge.net.au>
> > Signed-off-by: Cong Wang <amwang@...hat.com>
> 
> I want to use something that will either break the build or
> automatically work if the type changes again.
> 
> So something like "X = (typeof(X)) ~0U;".

I think you mean ~(typeof(X))0.

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

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