[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20111107134401.21cb3bf0@nehalam.linuxnetplumber.net>
Date: Mon, 7 Nov 2011 13:44:01 -0800
From: Stephen Hemminger <shemminger@...tta.com>
To: David Lamparter <equinox@...c24.net>
Cc: netdev <netdev@...r.kernel.org>, Patrick McHardy <kaber@...sh.net>
Subject: Re: [PATCH 1/2] net: vlan: 802.1ad S-VLAN support
On Sat, 5 Nov 2011 17:54:14 +0100
David Lamparter <equinox@...c24.net> wrote:
> +#define vlangrp_for_each_dev(i, grp, vlandev) \
> + for (i = 0; i < VLAN_N_VID * VLAN_N_PROTOCOL; i++) \
> + if ((vlandev = vlan_group_get_device_pidx(grp, \
> + i / VLAN_N_VID, i % VLAN_N_VID)))
> + /* { code here } */
> +
Please just open code this. Macro's make the code harder
to parse for humans. There are a few exceptions like.
LIST_FOREACH_RCU()
--
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