]> git.feebdaed.xyz Git - 0xmirror/ovs.git/commitdiff
netdev: Remove legacy duplex API.
authorDavid Marchand <david.marchand@redhat.com>
Wed, 29 Oct 2025 15:23:48 +0000 (16:23 +0100)
committerIlya Maximets <i.maximets@ovn.org>
Thu, 30 Oct 2025 21:33:49 +0000 (22:33 +0100)
This API was announcing duplex capability based on a fixed list of known
link speeds.
It is now unneeded with the new duplex API.

Acked-by: Eelco Chaudron <echaudro@redhat.com>
Acked-by: Mike Pattrick <mkp@redhat.com>
Signed-off-by: David Marchand <david.marchand@redhat.com>
Signed-off-by: Ilya Maximets <i.maximets@ovn.org>
include/openvswitch/netdev.h
lib/netdev.c

index 56dff57725a1858672b094de0e61cd59b549c9b3..8212ffb00e30c7cd930c492dc8e2d705681b6bf0 100644 (file)
@@ -135,7 +135,6 @@ int netdev_get_features(const struct netdev *,
 int netdev_get_speed(const struct netdev *, uint32_t *current, uint32_t *max);
 uint64_t netdev_features_to_bps(enum netdev_features features,
                                 uint64_t default_bps);
-bool netdev_features_is_full_duplex(enum netdev_features features);
 int netdev_get_duplex(const struct netdev *, bool *full_duplex);
 int netdev_set_advertisements(struct netdev *, enum netdev_features advertise);
 void netdev_features_format(struct ds *, enum netdev_features);
index 82bb13ce04c6e3c1201c6424cc3eedd1d914e388..6a05e9a7e53cdde08ae70b99808169fcd4c179a3 100644 (file)
@@ -1288,16 +1288,6 @@ netdev_features_to_bps(enum netdev_features features,
                                      : default_bps);
 }
 
-/* Returns true if any of the NETDEV_F_* bits that indicate a full-duplex link
- * are set in 'features', otherwise false. */
-bool
-netdev_features_is_full_duplex(enum netdev_features features)
-{
-    return (features & (NETDEV_F_10MB_FD | NETDEV_F_100MB_FD | NETDEV_F_1GB_FD
-                        | NETDEV_F_10GB_FD | NETDEV_F_40GB_FD
-                        | NETDEV_F_100GB_FD | NETDEV_F_1TB_FD)) != 0;
-}
-
 /* Stores the duplex capability of 'netdev' into 'full_duplex'.
  *
  * Some network devices may not implement support for this function.