lag.h 409 B

123456789101112131415161718
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef _LINUX_IF_LAG_H
  3. #define _LINUX_IF_LAG_H
  4. #include <linux/netdevice.h>
  5. #include <linux/if_team.h>
  6. #include <net/bonding.h>
  7. static inline bool net_lag_port_dev_txable(const struct net_device *port_dev)
  8. {
  9. if (netif_is_team_port(port_dev))
  10. return team_port_dev_txable(port_dev);
  11. else
  12. return bond_is_active_slave_dev(port_dev);
  13. }
  14. #endif /* _LINUX_IF_LAG_H */