From: Antoine Tenart <antoine.tenart@bootlin.com>
To: David Ahern <dsahern@gmail.com>
Cc: Antoine Tenart <antoine.tenart@bootlin.com>,
sd@queasysnail.net, netdev@vger.kernel.org
Subject: Re: [PATCH iproute2-next 1/2] macsec: report the offloading mode currently selected
Date: Wed, 29 Jan 2020 12:12:59 +0100 [thread overview]
Message-ID: <20200129111259.GA3102@kwain> (raw)
In-Reply-To: <69ba6f7f-9f52-a7fb-7608-955cdb200dd1@gmail.com>
Hello David,
On Mon, Jan 27, 2020 at 09:41:21AM -0700, David Ahern wrote:
> On 1/20/20 1:18 PM, Antoine Tenart wrote:
> > @@ -997,6 +1002,19 @@ static int process(struct nlmsghdr *n, void *arg)
> > if (attrs[MACSEC_ATTR_RXSC_LIST])
> > print_rxsc_list(attrs[MACSEC_ATTR_RXSC_LIST]);
> >
> > + if (attrs[MACSEC_ATTR_OFFLOAD]) {
> > + struct rtattr *attrs_offload[MACSEC_OFFLOAD_ATTR_MAX + 1];
> > + __u8 offload;
> > +
> > + parse_rtattr_nested(attrs_offload, MACSEC_OFFLOAD_ATTR_MAX,
> > + attrs[MACSEC_ATTR_OFFLOAD]);
> > +
> > + offload = rta_getattr_u8(attrs_offload[MACSEC_OFFLOAD_ATTR_TYPE]);
> > + print_string(PRINT_ANY, "offload",
> > + " offload: %s ", offload_str[offload]);
>
> you should be an accessor around offload_str[offload] to handle a future
> change adding a new type.
Good idea, I'll do that.
Thanks!
Antoine
--
Antoine Ténart, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
next prev parent reply other threads:[~2020-01-29 11:13 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-20 20:18 [PATCH iproute2-next 0/2] macsec: add offloading support Antoine Tenart
2020-01-20 20:18 ` [PATCH iproute2-next 1/2] macsec: report the offloading mode currently selected Antoine Tenart
2020-01-27 16:41 ` David Ahern
2020-01-29 11:12 ` Antoine Tenart [this message]
2020-01-20 20:18 ` [PATCH iproute2-next 2/2] macsec: add support for changing the offloading mode Antoine Tenart
2020-01-27 16:44 ` David Ahern
2020-01-28 10:36 ` Sabrina Dubroca
2020-01-28 10:36 ` [PATCH iproute2-next 0/2] macsec: add offloading support Sabrina Dubroca
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200129111259.GA3102@kwain \
--to=antoine.tenart@bootlin.com \
--cc=dsahern@gmail.com \
--cc=netdev@vger.kernel.org \
--cc=sd@queasysnail.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.