Lines Matching refs:features

1811 	if (unlikely(dev->features & NETIF_F_LRO))  in netif_disable_lro()
1835 if (unlikely(dev->features & NETIF_F_GRO_HW)) in dev_disable_gro_hw()
3533 name, dev ? &dev->features : &null_features, in skb_warn_bad_offload()
3677 if (!(dev->features & NETIF_F_HIGHDMA)) { in illegal_highdma()
3695 netdev_features_t features, in net_mpls_features() argument
3699 features &= skb->dev->mpls_features; in net_mpls_features()
3701 return features; in net_mpls_features()
3705 netdev_features_t features, in net_mpls_features() argument
3708 return features; in net_mpls_features()
3713 netdev_features_t features) in harmonize_features() argument
3718 features = net_mpls_features(skb, features, type); in harmonize_features()
3721 !can_checksum_protocol(features, type)) { in harmonize_features()
3722 features &= ~(NETIF_F_CSUM_MASK | NETIF_F_GSO_MASK); in harmonize_features()
3725 features &= ~NETIF_F_SG; in harmonize_features()
3727 return features; in harmonize_features()
3732 netdev_features_t features) in passthru_features_check() argument
3734 return features; in passthru_features_check()
3740 netdev_features_t features) in dflt_features_check() argument
3742 return vlan_features_check(skb, features); in dflt_features_check()
3747 netdev_features_t features) in gso_features_check() argument
3752 return features & ~NETIF_F_GSO_MASK; in gso_features_check()
3755 return features & ~NETIF_F_GSO_MASK; in gso_features_check()
3759 return features & ~NETIF_F_GSO_MASK; in gso_features_check()
3769 features &= ~dev->gso_partial_features; in gso_features_check()
3779 features &= ~NETIF_F_TSO_MANGLEID; in gso_features_check()
3782 return features; in gso_features_check()
3788 netdev_features_t features = dev->features; in netif_skb_features() local
3791 features = gso_features_check(skb, dev, features); in netif_skb_features()
3798 features &= dev->hw_enc_features; in netif_skb_features()
3801 features = netdev_intersect_features(features, in netif_skb_features()
3807 features &= dev->netdev_ops->ndo_features_check(skb, dev, in netif_skb_features()
3808 features); in netif_skb_features()
3810 features &= dflt_features_check(skb, dev, features); in netif_skb_features()
3812 return harmonize_features(skb, features); in netif_skb_features()
3862 netdev_features_t features) in validate_xmit_vlan() argument
3865 !vlan_hw_offload_capable(features, skb->vlan_proto)) in validate_xmit_vlan()
3871 const netdev_features_t features) in skb_csum_hwoffload_help() argument
3874 return !!(features & NETIF_F_SCTP_CRC) ? 0 : in skb_csum_hwoffload_help()
3877 if (features & NETIF_F_HW_CSUM) in skb_csum_hwoffload_help()
3880 if (features & (NETIF_F_IP_CSUM | NETIF_F_IPV6_CSUM)) { in skb_csum_hwoffload_help()
3929 netdev_features_t features; in validate_xmit_skb() local
3935 features = netif_skb_features(skb); in validate_xmit_skb()
3936 skb = validate_xmit_vlan(skb, features); in validate_xmit_skb()
3944 if (netif_needs_gso(skb, features)) { in validate_xmit_skb()
3947 segs = skb_gso_segment(skb, features); in validate_xmit_skb()
3955 if (skb_needs_linearize(skb, features) && in validate_xmit_skb()
3970 if (skb_csum_hwoffload_help(skb, features)) in validate_xmit_skb()
3975 skb = validate_xmit_xfrm(skb, features, again); in validate_xmit_skb()
4856 !(dev->features & NETIF_F_NTUPLE)) in set_rps_cpu()
10606 struct net_device *upper, netdev_features_t features) in netdev_sync_upper_features() argument
10615 && (features & feature)) { in netdev_sync_upper_features()
10618 features &= ~feature; in netdev_sync_upper_features()
10622 return features; in netdev_sync_upper_features()
10626 struct net_device *lower, netdev_features_t features) in netdev_sync_lower_features() argument
10634 if (!(features & feature) && (lower->features & feature)) { in netdev_sync_lower_features()
10641 if (unlikely(lower->features & feature)) in netdev_sync_lower_features()
10651 static bool netdev_has_ip_or_hw_csum(netdev_features_t features) in netdev_has_ip_or_hw_csum() argument
10654 bool ip_csum = (features & ip_csum_mask) == ip_csum_mask; in netdev_has_ip_or_hw_csum()
10655 bool hw_csum = features & NETIF_F_HW_CSUM; in netdev_has_ip_or_hw_csum()
10661 netdev_features_t features) in netdev_fix_features() argument
10664 if ((features & NETIF_F_HW_CSUM) && in netdev_fix_features()
10665 (features & (NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM))) { in netdev_fix_features()
10667 features &= ~(NETIF_F_IP_CSUM|NETIF_F_IPV6_CSUM); in netdev_fix_features()
10671 if ((features & NETIF_F_ALL_TSO) && !(features & NETIF_F_SG)) { in netdev_fix_features()
10673 features &= ~NETIF_F_ALL_TSO; in netdev_fix_features()
10676 if ((features & NETIF_F_TSO) && !(features & NETIF_F_HW_CSUM) && in netdev_fix_features()
10677 !(features & NETIF_F_IP_CSUM)) { in netdev_fix_features()
10679 features &= ~NETIF_F_TSO; in netdev_fix_features()
10680 features &= ~NETIF_F_TSO_ECN; in netdev_fix_features()
10683 if ((features & NETIF_F_TSO6) && !(features & NETIF_F_HW_CSUM) && in netdev_fix_features()
10684 !(features & NETIF_F_IPV6_CSUM)) { in netdev_fix_features()
10686 features &= ~NETIF_F_TSO6; in netdev_fix_features()
10690 if ((features & NETIF_F_TSO_MANGLEID) && !(features & NETIF_F_TSO)) in netdev_fix_features()
10691 features &= ~NETIF_F_TSO_MANGLEID; in netdev_fix_features()
10694 if ((features & NETIF_F_ALL_TSO) == NETIF_F_TSO_ECN) in netdev_fix_features()
10695 features &= ~NETIF_F_TSO_ECN; in netdev_fix_features()
10698 if ((features & NETIF_F_GSO) && !(features & NETIF_F_SG)) { in netdev_fix_features()
10700 features &= ~NETIF_F_GSO; in netdev_fix_features()
10704 if ((features & dev->gso_partial_features) && in netdev_fix_features()
10705 !(features & NETIF_F_GSO_PARTIAL)) { in netdev_fix_features()
10708 features &= ~dev->gso_partial_features; in netdev_fix_features()
10711 if (!(features & NETIF_F_RXCSUM)) { in netdev_fix_features()
10717 if (features & NETIF_F_GRO_HW) { in netdev_fix_features()
10719 features &= ~NETIF_F_GRO_HW; in netdev_fix_features()
10724 if (features & NETIF_F_RXFCS) { in netdev_fix_features()
10725 if (features & NETIF_F_LRO) { in netdev_fix_features()
10727 features &= ~NETIF_F_LRO; in netdev_fix_features()
10730 if (features & NETIF_F_GRO_HW) { in netdev_fix_features()
10732 features &= ~NETIF_F_GRO_HW; in netdev_fix_features()
10736 if ((features & NETIF_F_GRO_HW) && (features & NETIF_F_LRO)) { in netdev_fix_features()
10738 features &= ~NETIF_F_LRO; in netdev_fix_features()
10741 if ((features & NETIF_F_HW_TLS_TX) && !netdev_has_ip_or_hw_csum(features)) { in netdev_fix_features()
10743 features &= ~NETIF_F_HW_TLS_TX; in netdev_fix_features()
10746 if ((features & NETIF_F_HW_TLS_RX) && !(features & NETIF_F_RXCSUM)) { in netdev_fix_features()
10748 features &= ~NETIF_F_HW_TLS_RX; in netdev_fix_features()
10751 if ((features & NETIF_F_GSO_UDP_L4) && !netdev_has_ip_or_hw_csum(features)) { in netdev_fix_features()
10753 features &= ~NETIF_F_GSO_UDP_L4; in netdev_fix_features()
10756 return features; in netdev_fix_features()
10762 netdev_features_t features; in __netdev_update_features() local
10769 features = netdev_get_wanted_features(dev); in __netdev_update_features()
10772 features = dev->netdev_ops->ndo_fix_features(dev, features); in __netdev_update_features()
10775 features = netdev_fix_features(dev, features); in __netdev_update_features()
10779 features = netdev_sync_upper_features(dev, upper, features); in __netdev_update_features()
10781 if (dev->features == features) in __netdev_update_features()
10785 &dev->features, &features); in __netdev_update_features()
10788 err = dev->netdev_ops->ndo_set_features(dev, features); in __netdev_update_features()
10795 err, &features, &dev->features); in __netdev_update_features()
10807 netdev_sync_lower_features(dev, lower, features); in __netdev_update_features()
10810 netdev_features_t diff = features ^ dev->features; in __netdev_update_features()
10821 if (features & NETIF_F_RX_UDP_TUNNEL_PORT) { in __netdev_update_features()
10822 dev->features = features; in __netdev_update_features()
10831 if (features & NETIF_F_HW_VLAN_CTAG_FILTER) { in __netdev_update_features()
10832 dev->features = features; in __netdev_update_features()
10840 if (features & NETIF_F_HW_VLAN_STAG_FILTER) { in __netdev_update_features()
10841 dev->features = features; in __netdev_update_features()
10848 dev->features = features; in __netdev_update_features()
11129 if (((dev->hw_features | dev->features) & in register_netdevice()
11151 dev->features |= NETIF_F_SOFT_FEATURES; in register_netdevice()
11154 dev->features |= NETIF_F_RX_UDP_TUNNEL_PORT; in register_netdevice()
11158 dev->wanted_features = dev->features & dev->hw_features; in register_netdevice()
12761 CACHELINE_ASSERT_GROUP_MEMBER(struct net_device, net_device_read_txrx, features); in net_dev_struct_check()