+ log_info("Set link description of %s to '%s'", name,
+ config->description);
+ }
+
+ if (config->speed || config->duplex) {
+ r = ethtool_set_speed(ctx->ethtool_fd, name,
+ config->speed, config->duplex);
+ if (r < 0)
+ log_warning("Could not set speed or duplex of %s to %u Mbytes (%s): %s",
+ name, config->speed, config->duplex, strerror(-r));
+ else
+ log_info("Set speed or duplex of %s to %u Mbytes (%s)", name,
+ config->speed, config->duplex);
+ }
+
+ if (config->wol) {
+ r = ethtool_set_wol(ctx->ethtool_fd, name, config->wol);
+ if (r < 0)
+ log_warning("Could not set WakeOnLan of %s to %s: %s",
+ name, config->wol, strerror(-r));
+ else
+ log_info("Set WakeOnLan of %s to %s", name, config->wol);
+ }
+
+ ifindex = udev_device_get_ifindex(device);
+ if (ifindex <= 0) {
+ log_warning("Could not find ifindex");
+ return -ENODEV;
+ }
+
+ r = rtnl_set_properties(ctx->rtnl, ifindex, config->name, config->mac, config->mtu);
+ if (r < 0) {
+ log_warning("Could not set Name, MACAddress or MTU on %s", name);
+ return r;