diff options
author | Antoine Tenart <antoine.tenart@bootlin.com> | 2020-01-13 23:31:41 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2020-01-14 11:31:41 -0800 |
commit | 0830e20b62ad156f7df5ff5b9c4cea280ebe8fef (patch) | |
tree | ca229e7e670ce278144e55fe61480ed40f76ff81 /include/net/macsec.h | |
parent | 76564261a7db80c5f5c624e0122a28787f266bdf (diff) | |
download | linux-rpi-0830e20b62ad156f7df5ff5b9c4cea280ebe8fef.tar.gz linux-rpi-0830e20b62ad156f7df5ff5b9c4cea280ebe8fef.tar.bz2 linux-rpi-0830e20b62ad156f7df5ff5b9c4cea280ebe8fef.zip |
net: macsec: introduce MACsec ops
This patch introduces MACsec ops for drivers to support offloading
MACsec operations.
Signed-off-by: Antoine Tenart <antoine.tenart@bootlin.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/macsec.h')
-rw-r--r-- | include/net/macsec.h | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/include/net/macsec.h b/include/net/macsec.h index 0b98803f92ec..16e7e5061178 100644 --- a/include/net/macsec.h +++ b/include/net/macsec.h @@ -195,4 +195,28 @@ struct macsec_context { u8 prepare:1; }; +/** + * struct macsec_ops - MACsec offloading operations + */ +struct macsec_ops { + /* Device wide */ + int (*mdo_dev_open)(struct macsec_context *ctx); + int (*mdo_dev_stop)(struct macsec_context *ctx); + /* SecY */ + int (*mdo_add_secy)(struct macsec_context *ctx); + int (*mdo_upd_secy)(struct macsec_context *ctx); + int (*mdo_del_secy)(struct macsec_context *ctx); + /* Security channels */ + int (*mdo_add_rxsc)(struct macsec_context *ctx); + int (*mdo_upd_rxsc)(struct macsec_context *ctx); + int (*mdo_del_rxsc)(struct macsec_context *ctx); + /* Security associations */ + int (*mdo_add_rxsa)(struct macsec_context *ctx); + int (*mdo_upd_rxsa)(struct macsec_context *ctx); + int (*mdo_del_rxsa)(struct macsec_context *ctx); + int (*mdo_add_txsa)(struct macsec_context *ctx); + int (*mdo_upd_txsa)(struct macsec_context *ctx); + int (*mdo_del_txsa)(struct macsec_context *ctx); +}; + #endif /* _NET_MACSEC_H_ */ |