[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1376556163.2626.11.camel@cr0>
Date: Thu, 15 Aug 2013 16:42:43 +0800
From: Cong Wang <amwang@...hat.com>
To: David Miller <davem@...emloft.net>
Cc: netdev@...r.kernel.org, tmb@...eia.org, libc-alpha@...rceware.org,
yoshfuji@...ux-ipv6.org, carlos@...hat.com
Subject: Re: [Patch net-next] net: sync some IP headers with glibc
On Wed, 2013-08-14 at 13:42 -0700, David Miller wrote:
> > -#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop
> options */
> > -#define IPPROTO_ROUTING 43 /* IPv6 routing
> header */
> > -#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation
> header */
> > -#define IPPROTO_ICMPV6 58 /*
> ICMPv6 */
> > -#define IPPROTO_NONE 59 /* IPv6 no next
> header */
> > -#define IPPROTO_DSTOPTS 60 /* IPv6 destination
> options */
> > -#define IPPROTO_MH 135 /* IPv6 mobility
> header */
> > +#if __UAPI_DEF_IPPROTO_V6
> > +enum {
> > + IPPROTO_HOPOPTS = 0, /* IPv6 hop-by-hop options
> */
>
> Again, do not reformat things, it's an unrelated change and makes
> this patch harder to review.
Hmm, for this one, the original format is hard to keep since this patch
changes macros to enum's. What this patch does here looks correct to me,
for reference, below is the original code:
#define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options
*/
#define IPPROTO_ROUTING 43 /* IPv6 routing header
*/
#define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header
*/
#define IPPROTO_ICMPV6 58 /* ICMPv6
*/
#define IPPROTO_NONE 59 /* IPv6 no next header
*/
#define IPPROTO_DSTOPTS 60 /* IPv6 destination options
*/
#define IPPROTO_MH 135 /* IPv6 mobility header
*/
and here is the code after patch:
#if __UAPI_DEF_IPPROTO_V6
enum {
IPPROTO_HOPOPTS = 0, /* IPv6 hop-by-hop options */
#define IPPROTO_HOPOPTS IPPROTO_HOPOPTS
IPPROTO_ROUTING = 43, /* IPv6 routing header */
#define IPPROTO_ROUTING IPPROTO_ROUTING
IPPROTO_FRAGMENT = 44, /* IPv6 fragmentation header */
#define IPPROTO_FRAGMENT IPPROTO_FRAGMENT
IPPROTO_ICMPV6 = 58, /* ICMPv6 */
#define IPPROTO_ICMPV6 IPPROTO_ICMPV6
IPPROTO_NONE = 59, /* IPv6 no next header */
#define IPPROTO_NONE IPPROTO_NONE
IPPROTO_DSTOPTS = 60, /* IPv6 destination options */
#define IPPROTO_DSTOPTS IPPROTO_DSTOPTS
IPPROTO_MH = 135, /* IPv6 mobility header */
#define IPPROTO_MH IPPROTO_MH
};
#endif /* __UAPI_DEF_IPPROTO_V6 */
Or I don't get your point?
Thanks.
--
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