/linux-master/drivers/net/wireless/mediatek/mt7601u/ |
H A D | util.c | 8 void mt76_remove_hdr_pad(struct sk_buff *skb) argument 10 int len = ieee80211_get_hdrlen_from_skb(skb); 12 memmove(skb->data + 2, skb->data, len); 13 skb_pull(skb, 2); 16 int mt76_insert_hdr_pad(struct sk_buff *skb) argument 18 int len = ieee80211_get_hdrlen_from_skb(skb); 24 ret = skb_cow(skb, 2); 28 skb_push(skb, 2); 29 memmove(skb [all...] |
/linux-master/tools/testing/selftests/bpf/progs/ |
H A D | test_skb_ctx.c | 11 int process(struct __sk_buff *skb) argument 15 if (skb->cb[i] != i + 1) 17 skb->cb[i]++; 19 skb->priority++; 20 skb->tstamp++; 21 skb->mark++; 23 if (skb->wire_len != 100) 25 if (skb->gso_segs != 8) 27 if (skb->gso_size != 10) 29 if (skb [all...] |
H A D | test_global_func3.c | 9 int f1(struct __sk_buff *skb) argument 11 return skb->len; 15 int f2(int val, struct __sk_buff *skb) argument 17 return f1(skb) + val; 21 int f3(int val, struct __sk_buff *skb, int var) argument 23 return f2(var, skb) + val; 27 int f4(struct __sk_buff *skb) argument 29 return f3(1, skb, 2); 33 int f5(struct __sk_buff *skb) argument 35 return f4(skb); 39 f6(struct __sk_buff *skb) argument 45 f7(struct __sk_buff *skb) argument 51 f8(struct __sk_buff *skb) argument 58 global_func3(struct __sk_buff *skb) argument [all...] |
H A D | test_global_func6.c | 9 int f1(struct __sk_buff *skb) argument 11 return skb->len; 14 int f3(int, struct __sk_buff *skb); 17 int f2(int val, struct __sk_buff *skb) argument 19 return f1(skb) + f3(val, skb + 1); /* type mismatch */ 23 int f3(int val, struct __sk_buff *skb) argument 25 return skb->ifindex * val; 30 int global_func6(struct __sk_buff *skb) argument 32 return f1(skb) [all...] |
H A D | test_global_func4.c | 9 int f1(struct __sk_buff *skb) argument 11 return skb->len; 15 int f2(int val, struct __sk_buff *skb) argument 17 return f1(skb) + val; 21 int f3(int val, struct __sk_buff *skb, int var) argument 23 return f2(var, skb) + val; 27 int f4(struct __sk_buff *skb) argument 29 return f3(1, skb, 2); 33 int f5(struct __sk_buff *skb) argument 35 return f4(skb); 39 f6(struct __sk_buff *skb) argument 45 f7(struct __sk_buff *skb) argument 52 global_func4(struct __sk_buff *skb) argument [all...] |
H A D | test_global_func2.c | 11 int f0(int var, struct __sk_buff *skb) argument 13 return skb->len; 17 int f1(struct __sk_buff *skb) argument 23 return f0(0, skb) + skb->len; 26 int f3(int, struct __sk_buff *skb, int); 29 int f2(int val, struct __sk_buff *skb) argument 31 return f1(skb) + f3(val, skb, 1); 35 int f3(int val, struct __sk_buff *skb, in argument 46 global_func2(struct __sk_buff *skb) argument [all...] |
H A D | test_global_func1.c | 11 int f0(int var, struct __sk_buff *skb) argument 15 return skb->len; 19 int f1(struct __sk_buff *skb) argument 25 return f0(0, skb) + skb->len; 28 int f3(int, struct __sk_buff *skb, int); 31 int f2(int val, struct __sk_buff *skb) argument 37 return f1(skb) + f3(val, skb, 1); 41 int f3(int val, struct __sk_buff *skb, in argument 52 global_func1(struct __sk_buff *skb) argument [all...] |
H A D | test_global_func5.c | 9 int f1(struct __sk_buff *skb) argument 11 return skb->len; 14 int f3(int, struct __sk_buff *skb); 17 int f2(int val, struct __sk_buff *skb) argument 19 return f1(skb) + f3(val, (void *)&val); /* type mismatch */ 23 int f3(int val, struct __sk_buff *skb) argument 25 return skb->ifindex * val; 30 int global_func5(struct __sk_buff *skb) argument 32 return f1(skb) + f2(2, skb) [all...] |
H A D | tailcall1.c | 15 int classifier_##x(struct __sk_buff *skb) \ 24 int entry(struct __sk_buff *skb) argument 29 bpf_tail_call_static(skb, &jmp_table, 0); 30 bpf_tail_call_static(skb, &jmp_table, 0); 31 bpf_tail_call_static(skb, &jmp_table, 0); 32 bpf_tail_call_static(skb, &jmp_table, 0); 34 bpf_tail_call_static(skb, &jmp_table, 1); 35 bpf_tail_call_static(skb, &jmp_table, 1); 36 bpf_tail_call_static(skb, &jmp_table, 1); 37 bpf_tail_call_static(skb, [all...] |
H A D | tailcall2.c | 14 int classifier_0(struct __sk_buff *skb) argument 16 bpf_tail_call_static(skb, &jmp_table, 1); 21 int classifier_1(struct __sk_buff *skb) argument 23 bpf_tail_call_static(skb, &jmp_table, 2); 28 int classifier_2(struct __sk_buff *skb) argument 34 int classifier_3(struct __sk_buff *skb) argument 36 bpf_tail_call_static(skb, &jmp_table, 4); 41 int classifier_4(struct __sk_buff *skb) argument 43 bpf_tail_call_static(skb, &jmp_table, 3); 48 int entry(struct __sk_buff *skb) argument [all...] |
/linux-master/drivers/net/ethernet/sfc/siena/ |
H A D | tx.h | 14 /* What TXQ type will satisfy the checksum offloads required for this skb? */ 15 static inline unsigned int efx_tx_csum_type_skb(struct sk_buff *skb) argument 17 if (skb->ip_summed != CHECKSUM_PARTIAL) 20 if (skb->encapsulation && 21 skb_checksum_start_offset(skb) == skb_inner_transport_offset(skb)) { 28 if (skb_shinfo(skb)->gso_segs > 1 && 29 !(skb_shinfo(skb)->gso_type & SKB_GSO_PARTIAL) && 30 (skb_shinfo(skb)->gso_type & SKB_GSO_UDP_TUNNEL_CSUM))
|
/linux-master/net/rxrpc/ |
H A D | skbuff.c | 17 #define select_skb_count(skb) (&rxrpc_n_rx_skbs) 22 void rxrpc_new_skb(struct sk_buff *skb, enum rxrpc_skb_trace why) argument 24 int n = atomic_inc_return(select_skb_count(skb)); 25 trace_rxrpc_skb(skb, refcount_read(&skb->users), n, why); 31 void rxrpc_see_skb(struct sk_buff *skb, enum rxrpc_skb_trace why) argument 33 if (skb) { 34 int n = atomic_read(select_skb_count(skb)); 35 trace_rxrpc_skb(skb, refcount_read(&skb 42 rxrpc_get_skb(struct sk_buff *skb, enum rxrpc_skb_trace why) argument 52 rxrpc_eaten_skb(struct sk_buff *skb, enum rxrpc_skb_trace why) argument 61 rxrpc_free_skb(struct sk_buff *skb, enum rxrpc_skb_trace why) argument 75 struct sk_buff *skb; local [all...] |
/linux-master/drivers/net/wireless/quantenna/qtnfmac/ |
H A D | switchdev.h | 11 static inline void qtnfmac_switch_mark_skb_flooded(struct sk_buff *skb) argument 13 skb->offload_fwd_mark = 1; 18 static inline void qtnfmac_switch_mark_skb_flooded(struct sk_buff *skb) argument
|
/linux-master/include/linux/ |
H A D | ip.h | 19 static inline struct iphdr *ip_hdr(const struct sk_buff *skb) argument 21 return (struct iphdr *)skb_network_header(skb); 24 static inline struct iphdr *inner_ip_hdr(const struct sk_buff *skb) argument 26 return (struct iphdr *)skb_inner_network_header(skb); 29 static inline struct iphdr *ipip_hdr(const struct sk_buff *skb) argument 31 return (struct iphdr *)skb_transport_header(skb); 34 static inline unsigned int ip_transport_len(const struct sk_buff *skb) argument 36 return ntohs(ip_hdr(skb)->tot_len) - skb_network_header_len(skb); 39 static inline unsigned int iph_totlen(const struct sk_buff *skb, cons argument 47 skb_ip_totlen(const struct sk_buff *skb) argument [all...] |
H A D | if_ether.h | 22 static inline struct ethhdr *eth_hdr(const struct sk_buff *skb) argument 24 return (struct ethhdr *)skb_mac_header(skb); 30 static inline struct ethhdr *skb_eth_hdr(const struct sk_buff *skb) argument 32 return (struct ethhdr *)skb->data; 35 static inline struct ethhdr *inner_eth_hdr(const struct sk_buff *skb) argument 37 return (struct ethhdr *)skb_inner_mac_header(skb); 40 int eth_header_parse(const struct sk_buff *skb, unsigned char *haddr);
|
/linux-master/net/xfrm/ |
H A D | xfrm_inout.h | 9 static inline void xfrm4_extract_header(struct sk_buff *skb) argument 11 const struct iphdr *iph = ip_hdr(skb); 13 XFRM_MODE_SKB_CB(skb)->ihl = sizeof(*iph); 14 XFRM_MODE_SKB_CB(skb)->id = iph->id; 15 XFRM_MODE_SKB_CB(skb)->frag_off = iph->frag_off; 16 XFRM_MODE_SKB_CB(skb)->tos = iph->tos; 17 XFRM_MODE_SKB_CB(skb)->ttl = iph->ttl; 18 XFRM_MODE_SKB_CB(skb)->optlen = iph->ihl * 4 - sizeof(*iph); 19 memset(XFRM_MODE_SKB_CB(skb)->flow_lbl, 0, 20 sizeof(XFRM_MODE_SKB_CB(skb) 23 xfrm6_extract_header(struct sk_buff *skb) argument 41 xfrm6_beet_make_header(struct sk_buff *skb) argument 55 xfrm4_beet_make_header(struct sk_buff *skb) argument [all...] |
/linux-master/net/core/ |
H A D | sock_destructor.h | 6 static inline bool is_skb_wmem(const struct sk_buff *skb) argument 8 return skb->destructor == sock_wfree || 9 skb->destructor == __sock_wfree || 10 (IS_ENABLED(CONFIG_INET) && skb->destructor == tcp_wfree);
|
H A D | gso.c | 9 * @skb: buffer to segment 13 struct sk_buff *skb_eth_gso_segment(struct sk_buff *skb, argument 22 segs = ptype->callbacks.gso_segment(skb, features); 34 * @skb: buffer to segment 37 struct sk_buff *skb_mac_gso_segment(struct sk_buff *skb, argument 42 int vlan_depth = skb->mac_len; 43 __be16 type = skb_network_protocol(skb, &vlan_depth); 48 __skb_pull(skb, vlan_depth); 53 segs = ptype->callbacks.gso_segment(skb, features); 59 __skb_push(skb, sk 66 skb_needs_check(const struct sk_buff *skb, bool tx_path) argument 88 __skb_gso_segment(struct sk_buff *skb, netdev_features_t features, bool tx_path) argument 143 skb_gso_transport_seglen(const struct sk_buff *skb) argument 178 skb_gso_network_seglen(const struct sk_buff *skb) argument 195 skb_gso_mac_seglen(const struct sk_buff *skb) argument 223 skb_gso_size_check(const struct sk_buff *skb, unsigned int seg_len, unsigned int max_len) argument 253 skb_gso_validate_network_len(const struct sk_buff *skb, unsigned int mtu) argument 268 skb_gso_validate_mac_len(const struct sk_buff *skb, unsigned int len) argument [all...] |
/linux-master/tools/perf/scripts/python/bin/ |
H A D | net_dropmonitor-record | 2 perf record -e skb:kfree_skb $@
|
/linux-master/tools/testing/selftests/bpf/ |
H A D | bpf_legacy.h | 10 #define load_byte(skb, off) __builtin_bpf_load_byte(off) 11 #define load_half(skb, off) __builtin_bpf_load_half(off) 12 #define load_word(skb, off) __builtin_bpf_load_word(off) 17 unsigned long long load_byte(void *skb, unsigned long long off) asm("llvm.bpf.load.byte"); 18 unsigned long long load_half(void *skb, unsigned long long off) asm("llvm.bpf.load.half"); 19 unsigned long long load_word(void *skb, unsigned long long off) asm("llvm.bpf.load.word");
|
/linux-master/drivers/net/can/dev/ |
H A D | skb.c | 41 /* Put the skb on the stack to be looped backed locally lateron 47 int can_put_echo_skb(struct sk_buff *skb, struct net_device *dev, argument 60 (skb->protocol != htons(ETH_P_CAN) && 61 skb->protocol != htons(ETH_P_CANFD) && 62 skb->protocol != htons(ETH_P_CANXL))) { 63 kfree_skb(skb); 68 skb = can_create_echo_skb(skb); 69 if (!skb) 73 skb 113 struct sk_buff *skb = priv->echo_skb[idx]; local 149 struct sk_buff *skb; local 182 struct sk_buff *skb = priv->echo_skb[idx]; local 195 init_can_skb_reserve(struct sk_buff *skb) argument 210 struct sk_buff *skb; local 233 struct sk_buff *skb; local 260 struct sk_buff *skb; local 291 struct sk_buff *skb; local 305 can_skb_headroom_valid(struct net_device *dev, struct sk_buff *skb) argument 342 can_dropped_invalid_skb(struct net_device *dev, struct sk_buff *skb) argument [all...] |
/linux-master/net/ipv6/ |
H A D | mcast_snoop.c | 14 static int ipv6_mc_check_ip6hdr(struct sk_buff *skb) argument 18 unsigned int offset = skb_network_offset(skb) + sizeof(*ip6h); 20 if (!pskb_may_pull(skb, offset)) 23 ip6h = ipv6_hdr(skb); 29 if (skb->len < len || len <= offset) 32 skb_set_transport_header(skb, offset); 37 static int ipv6_mc_check_exthdrs(struct sk_buff *skb) argument 44 ip6h = ipv6_hdr(skb); 50 offset = skb_network_offset(skb) + sizeof(*ip6h); 51 offset = ipv6_skip_exthdr(skb, offse 64 ipv6_mc_check_mld_reportv2(struct sk_buff *skb) argument 73 ipv6_mc_check_mld_query(struct sk_buff *skb) argument 106 ipv6_mc_check_mld_msg(struct sk_buff *skb) argument 129 ipv6_mc_validate_checksum(struct sk_buff *skb) argument 134 ipv6_mc_check_icmpv6(struct sk_buff *skb) argument 172 ipv6_mc_check_mld(struct sk_buff *skb) argument [all...] |
/linux-master/include/net/ |
H A D | codel_qdisc.h | 61 static struct codel_skb_cb *get_codel_cb(const struct sk_buff *skb) argument 63 qdisc_cb_private_validate(skb, sizeof(struct codel_skb_cb)); 64 return (struct codel_skb_cb *)qdisc_skb_cb(skb)->data; 67 static codel_time_t codel_get_enqueue_time(const struct sk_buff *skb) argument 69 return get_codel_cb(skb)->enqueue_time; 72 static void codel_set_enqueue_time(struct sk_buff *skb) argument 74 get_codel_cb(skb)->enqueue_time = codel_get_time();
|
H A D | gso.h | 8 /* Keeps track of mac header offset relative to skb->head. 10 * For non-tunnel skb it points to skb_mac_header() and for 11 * tunnel skb it points to outer mac header. 24 #define SKB_GSO_CB(skb) ((struct skb_gso_cb *)((skb)->cb + SKB_GSO_CB_OFFSET)) 32 static inline int gso_pskb_expand_head(struct sk_buff *skb, int extra) argument 37 headroom = skb_headroom(skb); 38 ret = pskb_expand_head(skb, extra, 0, GFP_ATOMIC); 42 new_headroom = skb_headroom(skb); 43 SKB_GSO_CB(skb) 47 gso_reset_checksum(struct sk_buff *skb, __wsum res) argument 65 gso_make_checksum(struct sk_buff *skb, __wsum res) argument 80 skb_gso_segment(struct sk_buff *skb, netdev_features_t features) argument 96 skb_gso_error_unwind(struct sk_buff *skb, __be16 protocol, int pulled_hlen, u16 mac_offset, int mac_len) argument [all...] |
/linux-master/net/mptcp/ |
H A D | fastopen.c | 13 struct sk_buff *skb; local 28 skb = skb_peek(&ssk->sk_receive_queue); 29 if (WARN_ON_ONCE(!skb)) 32 /* dequeue the skb from sk receive queue */ 33 __skb_unlink(skb, &ssk->sk_receive_queue); 34 skb_ext_reset(skb); 35 skb_orphan(skb); 40 tp->copied_seq += skb->len; 41 subflow->ssn_offset += skb->len; 46 MPTCP_SKB_CB(skb) 66 struct sk_buff *skb; local [all...] |