[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <200706230142.41188.mb@bu3sch.de>
Date: Sat, 23 Jun 2007 01:42:41 +0200
From: Michael Buesch <mb@...sch.de>
To: "C. Scott Ananian" <cscott@...top.org>
Cc: netdev@...r.kernel.org
Subject: Re: [RFD] First draft of RDNSS-in-RA support for IPv6 DNS autoconfiguration
On Saturday 23 June 2007 01:26:19 C. Scott Ananian wrote:
> +struct rdns6_info {
> + rwlock_t lock;
> + struct timer_list expiry_timer;
> + struct rdns6_entry * rdnss_list;
> + struct inet6_dev * in6_dev; /* back pointer for netlink notify */
> + int expire_all : 1, /* remove entries on ifdown */
> + free_me : 1; /* safely free this struct */
> +};
Sparse will complain about that.
I suggest you do:
+struct rdns6_info {
+ rwlock_t lock;
+ struct timer_list expiry_timer;
+ struct rdns6_entry * rdnss_list;
+ struct inet6_dev * in6_dev; /* back pointer for netlink notify */
+ u8 expire_all; /* remove entries on ifdown */
+ u8 free_me; /* safely free this struct */
+};
Will generate better code and
struct size shouldn't increase. So it's a net win.
--
Greetings Michael.
-
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