]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/blobdiff - net/ipv4/devinet.c
net: core: rcu-ify rtnl af_ops
[mirror_ubuntu-bionic-kernel.git] / net / ipv4 / devinet.c
index 7ce22a2c07ce07ac2cd4cafb5aff6ec8d074531f..6d9b072d903b011f94d0226264a4edadd9a60eb0 100644 (file)
@@ -1757,7 +1757,7 @@ static int inet_validate_link_af(const struct net_device *dev,
        struct nlattr *a, *tb[IFLA_INET_MAX+1];
        int err, rem;
 
-       if (dev && !__in_dev_get_rtnl(dev))
+       if (dev && !__in_dev_get_rcu(dev))
                return -EAFNOSUPPORT;
 
        err = nla_parse_nested(tb, IFLA_INET_MAX, nla, inet_af_policy, NULL);
@@ -1781,7 +1781,7 @@ static int inet_validate_link_af(const struct net_device *dev,
 
 static int inet_set_link_af(struct net_device *dev, const struct nlattr *nla)
 {
-       struct in_device *in_dev = __in_dev_get_rtnl(dev);
+       struct in_device *in_dev = __in_dev_get_rcu(dev);
        struct nlattr *a, *tb[IFLA_INET_MAX+1];
        int rem;