public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH iproute2-next 0/2] macsec: add offloading support
@ 2020-04-24  8:38 Igor Russkikh
  2020-04-24  8:38 ` [PATCH iproute2-next 1/2] macsec: add support for MAC offload Igor Russkikh
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Igor Russkikh @ 2020-04-24  8:38 UTC (permalink / raw)
  To: netdev; +Cc: dsahern, stephen, Mark Starovoytov

From: Mark Starovoytov <mstarovoitov@marvell.com>

This series adds support for selecting the offloading mode of a MACsec
interface at link creation time.
Available modes are for now 'off', 'phy' and 'mac', 'off' being the default
when an interface is created.

First patch adds support for MAC offloading.

Last patch allows a user to change the offloading mode at runtime
through a new attribute, `ip link add link ... offload`:

  # ip link add link enp1s0 type macsec encrypt on offload off
  # ip link add link enp1s0 type macsec encrypt on offload phy
  # ip link add link enp1s0 type macsec encrypt on offload mac

Mark Starovoytov (2):
  macsec: add support for MAC offload
  macsec: add support for specifying offload at link add time

 ip/ipmacsec.c        | 23 ++++++++++++++++++++++-
 man/man8/ip-macsec.8 | 10 ++++++++--
 2 files changed, 30 insertions(+), 3 deletions(-)

-- 
2.20.1


^ permalink raw reply	[flat|nested] 6+ messages in thread
* [PATCH iproute2-next 0/2] macsec: add offloading support
@ 2020-01-20 20:18 Antoine Tenart
  2020-01-28 10:36 ` Sabrina Dubroca
  0 siblings, 1 reply; 6+ messages in thread
From: Antoine Tenart @ 2020-01-20 20:18 UTC (permalink / raw)
  To: dsahern, sd; +Cc: Antoine Tenart, netdev

Hello,

This series adds support for selecting and reporting the offloading mode
of a MACsec interface. Available modes are for now 'off' and 'phy',
'off' being the default when an interface is created. Modes are not only
'off' and 'on' as the MACsec operations can be offloaded to multiple
kinds of specialized hardware devices, at least to PHYs and Ethernet
MACs. The later isn't currently supported in the kernel though.

The first patch adds support for reporting the offloading mode currently
selected for a given MACsec interface through the `ip macsec show`
command:

   # ip macsec show
   18: macsec0: protect on validate strict sc off sa off encrypt on send_sci on end_station off scb off replay off
       cipher suite: GCM-AES-128, using ICV length 16
       TXSC: 3e5035b67c860001 on SA 0
           0: PN 1, state on, key 00000000000000000000000000000000
       RXSC: b4969112700f0001, state on
           0: PN 1, state on, key 01000000000000000000000000000000
->     offload: phy
   19: macsec1: protect on validate strict sc off sa off encrypt on send_sci on end_station off scb off replay off
       cipher suite: GCM-AES-128, using ICV length 16
       TXSC: 3e5035b67c880001 on SA 0
           1: PN 1, state on, key 00000000000000000000000000000000
       RXSC: b4969112700f0001, state on
           1: PN 1, state on, key 01000000000000000000000000000000
->     offload: off

The second patch allows an user to change the offloading mode at runtime
through a new subcommand, `ip macsec offload`:

  # ip macsec offload macsec0 phy
  # ip macsec offload macsec0 off

If a mode isn't supported, `ip macsec offload` will report an issue
(-EOPNOTSUPP).

One thing not supported in this series would be the ability to list all
supported modes (for now 'off' and 'phy') depending on the h/w interface
capabilities. This can come up in a later patch, as this is not critical
to get the feature used, but I would like this to be compatible with the
current series. I can think of 2 possibilities: either through
`ip macsec show` or through `ip macsec offload` (for example when no
argument is given). What are your thoughts on this?

Thanks!
Antoine

Antoine Tenart (2):
  macsec: report the offloading mode currently selected
  macsec: add support for changing the offloading mode

 ip/ipmacsec.c | 63 +++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 63 insertions(+)

-- 
2.24.1


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2020-04-26 18:33 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-04-24  8:38 [PATCH iproute2-next 0/2] macsec: add offloading support Igor Russkikh
2020-04-24  8:38 ` [PATCH iproute2-next 1/2] macsec: add support for MAC offload Igor Russkikh
2020-04-24  8:38 ` [PATCH iproute2-next 2/2] macsec: add support for specifying offload at link add time Igor Russkikh
2020-04-26 18:33 ` [PATCH iproute2-next 0/2] macsec: add offloading support David Ahern
  -- strict thread matches above, loose matches on Subject: below --
2020-01-20 20:18 Antoine Tenart
2020-01-28 10:36 ` Sabrina Dubroca

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox