diff options
author | Karsten Graul <kgraul@linux.ibm.com> | 2021-09-14 11:35:07 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2021-09-14 14:49:10 +0300 |
commit | 3c572145c24e21c24e1cd0fd168011eaba85da8e (patch) | |
tree | 61524c08f38942c6a9477d717f479f8af34e5281 /net/smc/smc_netlink.c | |
parent | 11a26c59fc510091facd0d80236ac848da844830 (diff) | |
download | linux-3c572145c24e21c24e1cd0fd168011eaba85da8e.tar.xz |
net/smc: add generic netlink support for system EID
With SMC-Dv2 users can configure if the static system EID should be used
during CLC handshake, or if only user EIDs are allowed.
Add generic netlink support to enable and disable the system EID, and
to retrieve the system EID and its current enabled state.
Signed-off-by: Karsten Graul <kgraul@linux.ibm.com>
Reviewed-by: Guvenc Gulce <guvenc@linux.ibm.com>
Signed-off-by: Guvenc Gulce <guvenc@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/smc/smc_netlink.c')
-rw-r--r-- | net/smc/smc_netlink.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/net/smc/smc_netlink.c b/net/smc/smc_netlink.c index 4548ff2df245..f13ab0661ed5 100644 --- a/net/smc/smc_netlink.c +++ b/net/smc/smc_netlink.c @@ -96,6 +96,21 @@ static const struct genl_ops smc_gen_nl_ops[] = { .flags = GENL_ADMIN_PERM, .doit = smc_nl_flush_ueid, }, + { + .cmd = SMC_NETLINK_DUMP_SEID, + /* can be retrieved by unprivileged users */ + .dumpit = smc_nl_dump_seid, + }, + { + .cmd = SMC_NETLINK_ENABLE_SEID, + .flags = GENL_ADMIN_PERM, + .doit = smc_nl_enable_seid, + }, + { + .cmd = SMC_NETLINK_DISABLE_SEID, + .flags = GENL_ADMIN_PERM, + .doit = smc_nl_disable_seid, + }, }; static const struct nla_policy smc_gen_nl_policy[2] = { |