|
@@ -5289,6 +5289,14 @@ int __netdev_update_features(struct net_device *dev)
|
|
return 1;
|
|
return 1;
|
|
}
|
|
}
|
|
|
|
|
|
|
|
+/**
|
|
|
|
+ * netdev_update_features - recalculate device features
|
|
|
|
+ * @dev: the device to check
|
|
|
|
+ *
|
|
|
|
+ * Recalculate dev->features set and send notifications if it
|
|
|
|
+ * has changed. Should be called after driver or hardware dependent
|
|
|
|
+ * conditions might have changed that influence the features.
|
|
|
|
+ */
|
|
void netdev_update_features(struct net_device *dev)
|
|
void netdev_update_features(struct net_device *dev)
|
|
{
|
|
{
|
|
if (__netdev_update_features(dev))
|
|
if (__netdev_update_features(dev))
|
|
@@ -5296,6 +5304,23 @@ void netdev_update_features(struct net_device *dev)
|
|
}
|
|
}
|
|
EXPORT_SYMBOL(netdev_update_features);
|
|
EXPORT_SYMBOL(netdev_update_features);
|
|
|
|
|
|
|
|
+/**
|
|
|
|
+ * netdev_change_features - recalculate device features
|
|
|
|
+ * @dev: the device to check
|
|
|
|
+ *
|
|
|
|
+ * Recalculate dev->features set and send notifications even
|
|
|
|
+ * if they have not changed. Should be called instead of
|
|
|
|
+ * netdev_update_features() if also dev->vlan_features might
|
|
|
|
+ * have changed to allow the changes to be propagated to stacked
|
|
|
|
+ * VLAN devices.
|
|
|
|
+ */
|
|
|
|
+void netdev_change_features(struct net_device *dev)
|
|
|
|
+{
|
|
|
|
+ __netdev_update_features(dev);
|
|
|
|
+ netdev_features_change(dev);
|
|
|
|
+}
|
|
|
|
+EXPORT_SYMBOL(netdev_change_features);
|
|
|
|
+
|
|
/**
|
|
/**
|
|
* netif_stacked_transfer_operstate - transfer operstate
|
|
* netif_stacked_transfer_operstate - transfer operstate
|
|
* @rootdev: the root or lower level device to transfer state from
|
|
* @rootdev: the root or lower level device to transfer state from
|