Subject: Re: [PATCH 2/2] netlink: add ethernet address policy types

From: Johannes Berg <[email-masked]>
Date: Mon, 17 Sep 2018 09:45:27 +0200

On Thu, 2018-09-13 at 22:39 +0200, Michal Kubecek wrote:

> > What about
> > #define NLA_FIELD_ETH_ADDR  { .type = NLA_BINARY_EXACT, .len = ETH_ALEN }
> > 
> > Or even
> > #define NLA_FIELD_BINARY_EXACT(_len)	{ .type = NLA_BINARY_EXACT, .len = (_len) }
> > #define NLA_FIELD_ETH_ADDR		NLA_FIELD_BINARY_EXACT(ETH_ALEN)
> > 
> > So that one would just:
> >    [MYADDR] = NLA_FIELD_ETH_ADDR,
> 
> Yes, that's how I understoold Johannes' proposal above.

I was really thinking of

	[MYADDR] = { NLA_FIELD_ETH_ADDR },

but it doesn't really matter much to me either way.

johannes