.. | .. |
---|
2635 | 2635 | bool active = false; |
---|
2636 | 2636 | unsigned int nr_ids; |
---|
2637 | 2637 | |
---|
| 2638 | + WARN_ON_ONCE(index >= dev->num_tx_queues); |
---|
| 2639 | + |
---|
2638 | 2640 | if (dev->num_tc) { |
---|
2639 | 2641 | /* Do not allow XPS on subordinate device directly */ |
---|
2640 | 2642 | num_tc = dev->num_tc; |
---|
.. | .. |
---|
3124 | 3126 | { |
---|
3125 | 3127 | if (in_irq() || irqs_disabled()) |
---|
3126 | 3128 | __dev_kfree_skb_irq(skb, reason); |
---|
| 3129 | + else if (unlikely(reason == SKB_REASON_DROPPED)) |
---|
| 3130 | + kfree_skb(skb); |
---|
3127 | 3131 | else |
---|
3128 | | - dev_kfree_skb(skb); |
---|
| 3132 | + consume_skb(skb); |
---|
3129 | 3133 | } |
---|
3130 | 3134 | EXPORT_SYMBOL(__dev_kfree_skb_any); |
---|
3131 | 3135 | |
---|
.. | .. |
---|
3323 | 3327 | type = eth->h_proto; |
---|
3324 | 3328 | } |
---|
3325 | 3329 | |
---|
3326 | | - return __vlan_get_protocol(skb, type, depth); |
---|
| 3330 | + return vlan_get_protocol_and_depth(skb, type, depth); |
---|
3327 | 3331 | } |
---|
3328 | 3332 | |
---|
3329 | 3333 | /** |
---|
.. | .. |
---|
3636 | 3640 | int skb_csum_hwoffload_help(struct sk_buff *skb, |
---|
3637 | 3641 | const netdev_features_t features) |
---|
3638 | 3642 | { |
---|
3639 | | - if (unlikely(skb->csum_not_inet)) |
---|
| 3643 | + if (unlikely(skb_csum_is_sctp(skb))) |
---|
3640 | 3644 | return !!(features & NETIF_F_SCTP_CRC) ? 0 : |
---|
3641 | 3645 | skb_crc32c_csum_help(skb); |
---|
3642 | 3646 | |
---|
.. | .. |
---|
4386 | 4390 | u32 next_cpu; |
---|
4387 | 4391 | u32 ident; |
---|
4388 | 4392 | |
---|
4389 | | - /* First check into global flow table if there is a match */ |
---|
4390 | | - ident = sock_flow_table->ents[hash & sock_flow_table->mask]; |
---|
| 4393 | + /* First check into global flow table if there is a match. |
---|
| 4394 | + * This READ_ONCE() pairs with WRITE_ONCE() from rps_record_sock_flow(). |
---|
| 4395 | + */ |
---|
| 4396 | + ident = READ_ONCE(sock_flow_table->ents[hash & sock_flow_table->mask]); |
---|
4391 | 4397 | if ((ident ^ hash) & ~rps_cpu_mask) |
---|
4392 | 4398 | goto try_rps; |
---|
4393 | 4399 | |
---|
.. | .. |
---|
6114 | 6120 | |
---|
6115 | 6121 | static void napi_skb_free_stolen_head(struct sk_buff *skb) |
---|
6116 | 6122 | { |
---|
| 6123 | + nf_reset_ct(skb); |
---|
6117 | 6124 | skb_dst_drop(skb); |
---|
6118 | 6125 | skb_ext_put(skb); |
---|
6119 | 6126 | kmem_cache_free(skbuff_head_cache, skb); |
---|
.. | .. |
---|
10298 | 10305 | BUG_ON(!list_empty(&dev->ptype_specific)); |
---|
10299 | 10306 | WARN_ON(rcu_access_pointer(dev->ip_ptr)); |
---|
10300 | 10307 | WARN_ON(rcu_access_pointer(dev->ip6_ptr)); |
---|
10301 | | -#if IS_ENABLED(CONFIG_DECNET) |
---|
10302 | | - WARN_ON(dev->dn_ptr); |
---|
10303 | | -#endif |
---|
| 10308 | + |
---|
10304 | 10309 | if (dev->priv_destructor) |
---|
10305 | 10310 | dev->priv_destructor(dev); |
---|
10306 | 10311 | if (dev->needs_free_netdev) |
---|