|
@@ -1103,6 +1103,15 @@ static int ppp_nl_newlink(struct net *src_net, struct net_device *dev,
|
|
}
|
|
}
|
|
|
|
|
|
conf.file = file;
|
|
conf.file = file;
|
|
|
|
+
|
|
|
|
+ /* Don't use device name generated by the rtnetlink layer when ifname
|
|
|
|
+ * isn't specified. Let ppp_dev_configure() set the device name using
|
|
|
|
+ * the PPP unit identifer as suffix (i.e. ppp<unit_id>). This allows
|
|
|
|
+ * userspace to infer the device name using to the PPPIOCGUNIT ioctl.
|
|
|
|
+ */
|
|
|
|
+ if (!tb[IFLA_IFNAME])
|
|
|
|
+ conf.ifname_is_set = false;
|
|
|
|
+
|
|
err = ppp_dev_configure(src_net, dev, &conf);
|
|
err = ppp_dev_configure(src_net, dev, &conf);
|
|
|
|
|
|
out_unlock:
|
|
out_unlock:
|