aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/netkit.c
diff options
context:
space:
mode:
authorJakub Kicinski <[email protected]>2023-12-01 00:10:40 +0000
committerJakub Kicinski <[email protected]>2023-12-01 00:11:19 +0000
commit975f2d73a99f35b57ffa2ad7bff8562225cdcfcb (patch)
treed6c9ce96cfd889281e003a310c79d5a12a3cf924 /drivers/net/netkit.c
parentnet: page_pool: fix general protection fault in page_pool_unlist (diff)
parentMerge tag 'net-6.7-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/netd... (diff)
downloadkernel-975f2d73a99f35b57ffa2ad7bff8562225cdcfcb.tar.gz
kernel-975f2d73a99f35b57ffa2ad7bff8562225cdcfcb.zip
Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net
Cross-merge networking fixes after downstream PR. No conflicts. Signed-off-by: Jakub Kicinski <[email protected]>
Diffstat (limited to 'drivers/net/netkit.c')
-rw-r--r--drivers/net/netkit.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/netkit.c b/drivers/net/netkit.c
index 97bd6705c241..39171380ccf2 100644
--- a/drivers/net/netkit.c
+++ b/drivers/net/netkit.c
@@ -851,6 +851,12 @@ static int netkit_change_link(struct net_device *dev, struct nlattr *tb[],
return -EACCES;
}
+ if (data[IFLA_NETKIT_PEER_INFO]) {
+ NL_SET_ERR_MSG_ATTR(extack, data[IFLA_NETKIT_PEER_INFO],
+ "netkit peer info cannot be changed after device creation");
+ return -EINVAL;
+ }
+
if (data[IFLA_NETKIT_POLICY]) {
attr = data[IFLA_NETKIT_POLICY];
policy = nla_get_u32(attr);