Home
last modified time | relevance | path

Searched refs:size (Results 1 – 25 of 339) sorted by relevance

12345678910>>...14

/net/wireless/
Dradiotap.c26 [IEEE80211_RADIOTAP_TSFT] = { .align = 8, .size = 8, },
27 [IEEE80211_RADIOTAP_FLAGS] = { .align = 1, .size = 1, },
28 [IEEE80211_RADIOTAP_RATE] = { .align = 1, .size = 1, },
29 [IEEE80211_RADIOTAP_CHANNEL] = { .align = 2, .size = 4, },
30 [IEEE80211_RADIOTAP_FHSS] = { .align = 2, .size = 2, },
31 [IEEE80211_RADIOTAP_DBM_ANTSIGNAL] = { .align = 1, .size = 1, },
32 [IEEE80211_RADIOTAP_DBM_ANTNOISE] = { .align = 1, .size = 1, },
33 [IEEE80211_RADIOTAP_LOCK_QUALITY] = { .align = 2, .size = 2, },
34 [IEEE80211_RADIOTAP_TX_ATTENUATION] = { .align = 2, .size = 2, },
35 [IEEE80211_RADIOTAP_DB_TX_ATTENUATION] = { .align = 2, .size = 2, },
[all …]
/net/bpf/
Dtest_run.c78 u32 size, u32 retval, u32 duration) in bpf_test_finish() argument
82 u32 copy_size = size; in bpf_test_finish()
95 if (copy_to_user(&uattr->test.data_size_out, &size, sizeof(size))) in bpf_test_finish()
108 static void *bpf_test_init(const union bpf_attr *kattr, u32 size, in bpf_test_init() argument
114 if (size < ETH_HLEN || size > PAGE_SIZE - headroom - tailroom) in bpf_test_init()
117 size = SKB_DATA_ALIGN(size); in bpf_test_init()
118 data = kzalloc(size + headroom + tailroom, GFP_USER); in bpf_test_init()
122 if (copy_from_user(data + headroom, data_in, size)) { in bpf_test_init()
133 u32 size = kattr->test.ctx_size_in; in bpf_ctx_init() local
145 err = bpf_check_uarg_tail_zero(data_in, max_size, size); in bpf_ctx_init()
[all …]
/net/ipv4/netfilter/
Darp_tables.c336 unsigned int oldpos, size; in mark_source_chains() local
355 size = e->next_offset; in mark_source_chains()
356 e = entry0 + pos + size; in mark_source_chains()
357 if (pos + size >= newinfo->size) in mark_source_chains()
360 pos += size; in mark_source_chains()
374 if (newpos >= newinfo->size) in mark_source_chains()
405 unsigned int size, in find_check_entry() argument
529 newinfo->size = repl->size; in translate_table()
544 xt_entry_foreach(iter, entry0, newinfo->size) { in translate_table()
546 entry0 + repl->size, in translate_table()
[all …]
Dip_tables.c206 xt_entry_foreach(iter, root, private->size - private->hook_entry[hook]) in trace_packet()
401 unsigned int oldpos, size; in mark_source_chains() local
419 size = e->next_offset; in mark_source_chains()
420 e = entry0 + pos + size; in mark_source_chains()
421 if (pos + size >= newinfo->size) in mark_source_chains()
424 pos += size; in mark_source_chains()
438 if (newpos >= newinfo->size) in mark_source_chains()
517 unsigned int size, in find_check_entry() argument
670 newinfo->size = repl->size; in translate_table()
684 xt_entry_foreach(iter, entry0, newinfo->size) { in translate_table()
[all …]
/net/core/
Dtso.c17 int size, bool is_last) in tso_build_hdr() argument
28 iph->tot_len = htons(size + hdr_len - mac_hdr_len); in tso_build_hdr()
33 iph->payload_len = htons(size + tcp_hdrlen(skb)); in tso_build_hdr()
47 void tso_build_data(struct sk_buff *skb, struct tso_t *tso, int size) in tso_build_data() argument
49 tso->tcp_seq += size; in tso_build_data()
50 tso->size -= size; in tso_build_data()
51 tso->data += size; in tso_build_data()
53 if ((tso->size == 0) && in tso_build_data()
58 tso->size = skb_frag_size(frag); in tso_build_data()
75 tso->size = skb_headlen(skb) - hdr_len; in tso_start()
[all …]
/net/atm/
Dresources.c199 int error, len, number, size = 0; in atm_dev_ioctl() local
227 size += sizeof(int); in atm_dev_ioctl()
228 if (size > len) { in atm_dev_ioctl()
232 tmp_buf = kmalloc(size, GFP_ATOMIC); in atm_dev_ioctl()
243 error = ((copy_to_user(buf, tmp_buf, size)) || in atm_dev_ioctl()
244 put_user(size, iobuf_len)) in atm_dev_ioctl()
286 size = strlen(dev->type) + 1; in atm_dev_ioctl()
287 if (copy_to_user(buf, dev->type, size)) { in atm_dev_ioctl()
293 size = ESI_LEN; in atm_dev_ioctl()
294 if (copy_to_user(buf, dev->esi, size)) { in atm_dev_ioctl()
[all …]
/net/ipv6/netfilter/
Dip6_tables.c231 xt_entry_foreach(iter, root, private->size - private->hook_entry[hook]) in trace_packet()
420 unsigned int oldpos, size; in mark_source_chains() local
438 size = e->next_offset; in mark_source_chains()
439 e = entry0 + pos + size; in mark_source_chains()
440 if (pos + size >= newinfo->size) in mark_source_chains()
443 pos += size; in mark_source_chains()
457 if (newpos >= newinfo->size) in mark_source_chains()
537 unsigned int size, in find_check_entry() argument
688 newinfo->size = repl->size; in translate_table()
702 xt_entry_foreach(iter, entry0, newinfo->size) { in translate_table()
[all …]
/net/9p/
Dprotocol.c46 size_t pdu_read(struct p9_fcall *pdu, void *data, size_t size) in pdu_read() argument
48 size_t len = min(pdu->size - pdu->offset, size); in pdu_read()
51 return size - len; in pdu_read()
54 static size_t pdu_write(struct p9_fcall *pdu, const void *data, size_t size) in pdu_write() argument
56 size_t len = min(pdu->capacity - pdu->size, size); in pdu_write()
57 memcpy(&pdu->sdata[pdu->size], data, len); in pdu_write()
58 pdu->size += len; in pdu_write()
59 return size - len; in pdu_write()
63 pdu_write_u(struct p9_fcall *pdu, struct iov_iter *from, size_t size) in pdu_write_u() argument
65 size_t len = min(pdu->capacity - pdu->size, size); in pdu_write_u()
[all …]
/net/ipv4/
Dtcp_bpf.c82 msg_rx->sg.size -= copy; in __tcp_bpf_recvmsg()
176 u32 size, copied = 0; in bpf_tcp_ingress() local
189 size = (apply && apply_bytes < sge->length) ? in bpf_tcp_ingress()
191 if (!sk_wmem_schedule(sk, size)) { in bpf_tcp_ingress()
197 sk_mem_charge(sk, size); in bpf_tcp_ingress()
198 sk_msg_xfer(tmp, msg, i, size); in bpf_tcp_ingress()
199 copied += size; in bpf_tcp_ingress()
205 apply_bytes -= size; in bpf_tcp_ingress()
233 int size, ret = 0; in tcp_bpf_push() local
240 size = (apply && apply_bytes < sge->length) ? in tcp_bpf_push()
[all …]
/net/netfilter/
Dxt_quota2.c87 size_t size; in quota2_log() local
93 size = NLMSG_SPACE(sizeof(*pm)); in quota2_log()
94 size = max(size, (size_t)NLMSG_GOODSIZE); in quota2_log()
95 log_skb = alloc_skb(size, GFP_ATOMIC); in quota2_log()
135 size_t size, loff_t *ppos) in quota_proc_read() argument
144 return simple_read_from_buffer(buf, size, ppos, tmp, tmp_size); in quota_proc_read()
148 size_t size, loff_t *ppos) in quota_proc_write() argument
153 if (size > sizeof(buf)) in quota_proc_write()
154 size = sizeof(buf); in quota_proc_write()
155 if (copy_from_user(buf, input, size) != 0) in quota_proc_write()
[all …]
Dx_tables.c273 static int xt_obj_to_user(u16 __user *psize, u16 size, in xt_obj_to_user() argument
277 if (put_user(size, psize)) in xt_obj_to_user()
293 int usersize, int size, int aligned_size) in xt_data_to_user() argument
295 usersize = usersize ? : size; in xt_data_to_user()
309 K->u.kernel.TYPE->TYPE##size, \
310 XT_ALIGN(K->u.kernel.TYPE->TYPE##size))
397 textify_hooks(char *buf, size_t size, unsigned int mask, uint8_t nfproto) in textify_hooks() argument
419 res = snprintf(p, size, "%s%s", np ? "/" : "", names[i]); in textify_hooks()
421 size -= res; in textify_hooks()
443 int xt_check_proc_name(const char *name, unsigned int size) in xt_check_proc_name() argument
[all …]
Dnft_byteorder.c23 u8 size; member
39 switch (priv->size) { in nft_byteorder_eval()
101 u32 size, len; in nft_byteorder_init() local
120 err = nft_parse_u32_check(tb[NFTA_BYTEORDER_SIZE], U8_MAX, &size); in nft_byteorder_init()
124 priv->size = size; in nft_byteorder_init()
126 switch (priv->size) { in nft_byteorder_init()
163 if (nla_put_be32(skb, NFTA_BYTEORDER_SIZE, htonl(priv->size))) in nft_byteorder_dump()
173 .size = NFT_EXPR_SIZE(sizeof(struct nft_byteorder)),
Dnf_conntrack_labels.c35 unsigned int size, i; in nf_connlabels_replace() local
43 size = sizeof(labels->bits); in nf_connlabels_replace()
44 if (size < (words32 * sizeof(u32))) in nf_connlabels_replace()
45 words32 = size / sizeof(u32); in nf_connlabels_replace()
51 size /= sizeof(u32); in nf_connlabels_replace()
52 for (i = words32; i < size; i++) /* pad */ in nf_connlabels_replace()
/net/ceph/
Dosdmap.c59 ceph_decode_need(p, end, (1+b->h.size) * sizeof(u32), bad); in crush_decode_uniform_bucket()
71 b->item_weights = kcalloc(b->h.size, sizeof(u32), GFP_NOFS); in crush_decode_list_bucket()
74 b->sum_weights = kcalloc(b->h.size, sizeof(u32), GFP_NOFS); in crush_decode_list_bucket()
77 ceph_decode_need(p, end, 2 * b->h.size * sizeof(u32), bad); in crush_decode_list_bucket()
78 for (j = 0; j < b->h.size; j++) { in crush_decode_list_bucket()
109 b->item_weights = kcalloc(b->h.size, sizeof(u32), GFP_NOFS); in crush_decode_straw_bucket()
112 b->straws = kcalloc(b->h.size, sizeof(u32), GFP_NOFS); in crush_decode_straw_bucket()
115 ceph_decode_need(p, end, 2 * b->h.size * sizeof(u32), bad); in crush_decode_straw_bucket()
116 for (j = 0; j < b->h.size; j++) { in crush_decode_straw_bucket()
130 b->item_weights = kcalloc(b->h.size, sizeof(u32), GFP_NOFS); in crush_decode_straw2_bucket()
[all …]
/net/smc/
Dsmc_cdc.h90 static inline void smc_curs_add(int size, union smc_host_cursor *curs, in smc_curs_add() argument
94 if (curs->count >= size) { in smc_curs_add()
96 curs->count -= size; in smc_curs_add()
166 static inline int smc_curs_diff(unsigned int size, in smc_curs_diff() argument
172 ((size - old->count) + new->count)); in smc_curs_diff()
180 static inline int smc_curs_comp(unsigned int size, in smc_curs_comp() argument
186 return -smc_curs_diff(size, new, old); in smc_curs_comp()
187 return smc_curs_diff(size, old, new); in smc_curs_comp()
193 static inline int smc_curs_diff_large(unsigned int size, in smc_curs_diff_large() argument
199 (size - old->count) + new->count + in smc_curs_diff_large()
[all …]
/net/batman-adv/
Dhash.c19 for (i = 0; i < hash->size; i++) { in batadv_hash_init()
44 struct batadv_hashtable *batadv_hash_new(u32 size) in batadv_hash_new() argument
52 hash->table = kmalloc_array(size, sizeof(*hash->table), GFP_ATOMIC); in batadv_hash_new()
56 hash->list_locks = kmalloc_array(size, sizeof(*hash->list_locks), in batadv_hash_new()
61 hash->size = size; in batadv_hash_new()
82 for (i = 0; i < hash->size; i++) in batadv_hash_set_lock_class()
Dfragmentation.c73 chain->size = 0; in batadv_frag_purge_orig()
119 chain->size = 0; in batadv_frag_init_chain()
176 chain->size = skb->len - hdr_size; in batadv_frag_insert_packet()
193 chain->size += skb->len - hdr_size; in batadv_frag_insert_packet()
206 chain->size += skb->len - hdr_size; in batadv_frag_insert_packet()
212 if (chain->size > batadv_frag_size_limit() || in batadv_frag_insert_packet()
220 chain->size = 0; in batadv_frag_insert_packet()
221 } else if (ntohs(frag_packet->total_size) == chain->size) { in batadv_frag_insert_packet()
224 chain->size = 0; in batadv_frag_insert_packet()
254 int size, hdr_size = sizeof(struct batadv_frag_packet); in batadv_frag_merge_packets() local
[all …]
/net/nfc/
Dllcp_commands.c314 u8 cmd, u16 size) in llcp_allocate_pdu() argument
323 size + LLCP_HEADER_SIZE, &err); in llcp_allocate_pdu()
363 u16 size = 0; in nfc_llcp_send_symm() local
372 size += LLCP_HEADER_SIZE; in nfc_llcp_send_symm()
373 size += dev->tx_headroom + dev->tx_tailroom + NFC_HEADER_SIZE; in nfc_llcp_send_symm()
375 skb = alloc_skb(size, GFP_KERNEL); in nfc_llcp_send_symm()
406 u16 size = 0; in nfc_llcp_send_connect() local
424 size += service_name_tlv_length; in nfc_llcp_send_connect()
438 size += miux_tlv_length; in nfc_llcp_send_connect()
445 size += rw_tlv_length; in nfc_llcp_send_connect()
[all …]
/net/wimax/
Dop-msg.c107 const void *msg, size_t size, in wimax_msg_alloc() argument
116 msg_size = nla_total_size(size) in wimax_msg_alloc()
143 result = nla_put(skb, WIMAX_GNL_MSG_DATA, size, msg); in wimax_msg_alloc()
146 "attribute: %d\n", msg, size, result); in wimax_msg_alloc()
169 const void *wimax_msg_data_len(struct sk_buff *msg, size_t *size) in wimax_msg_data_len() argument
180 *size = nla_len(nla); in wimax_msg_data_len()
262 size_t size = skb->len; in wimax_msg_send() local
265 d_printf(1, dev, "CTX: wimax msg, %zu bytes\n", size); in wimax_msg_send()
266 d_dump(2, dev, msg, size); in wimax_msg_send()
295 const void *buf, size_t size, gfp_t gfp_flags) in wimax_msg() argument
[all …]
/net/sunrpc/xprtrdma/
Dbackchannel.c174 size_t size; in rpcrdma_bc_rqst_get() local
193 size = min_t(size_t, r_xprt->rx_ep.rep_inline_recv, PAGE_SIZE); in rpcrdma_bc_rqst_get()
194 req = rpcrdma_req_create(r_xprt, size, GFP_KERNEL); in rpcrdma_bc_rqst_get()
202 xdr_buf_init(&rqst->rq_snd_buf, rdmab_data(req->rl_sendbuf), size); in rpcrdma_bc_rqst_get()
225 size_t size; in rpcrdma_bc_receive_call() local
229 size = xdr_stream_remaining(&rep->rr_stream); in rpcrdma_bc_receive_call()
233 __func__, be32_to_cpup(p), size); in rpcrdma_bc_receive_call()
234 pr_info("RPC: %s: %*ph\n", __func__, size, p); in rpcrdma_bc_receive_call()
244 rqst->rq_private_buf.len = size; in rpcrdma_bc_receive_call()
249 buf->head[0].iov_len = size; in rpcrdma_bc_receive_call()
[all …]
/net/bluetooth/cmtp/
Dcore.c110 int size; in cmtp_add_msgpart() local
114 size = (skb) ? skb->len + count : count; in cmtp_add_msgpart()
116 nskb = alloc_skb(size, GFP_ATOMIC); in cmtp_add_msgpart()
213 unsigned int size, tail; in cmtp_process_transmit() local
233 size = min_t(uint, ((tail < 258) ? (tail - 2) : (tail - 3)), skb->len); in cmtp_process_transmit()
243 if (size < 256) { in cmtp_process_transmit()
247 | ((skb->len == size) ? 0x00 : 0x01); in cmtp_process_transmit()
248 hdr[1] = size; in cmtp_process_transmit()
253 | ((skb->len == size) ? 0x00 : 0x01); in cmtp_process_transmit()
254 hdr[1] = size & 0xff; in cmtp_process_transmit()
[all …]
/net/vmw_vsock/
Dvmci_transport.c122 u64 size, in vmci_transport_packet_init() argument
145 pkt->u.size = 0; in vmci_transport_packet_init()
150 pkt->u.size = size; in vmci_transport_packet_init()
161 pkt->u.size = 0; in vmci_transport_packet_init()
175 pkt->u.size = size; in vmci_transport_packet_init()
195 u64 size, in __vmci_transport_send_control_pkt() argument
204 vmci_transport_packet_init(pkt, src, dst, type, size, mode, wait, in __vmci_transport_send_control_pkt()
216 u64 size, in vmci_transport_reply_control_pkt_fast() argument
230 size, mode, wait, in vmci_transport_reply_control_pkt_fast()
240 u64 size, in vmci_transport_send_control_pkt_bh() argument
[all …]
/net/dccp/
Dtrace.h16 TP_PROTO(struct sock *sk, size_t size),
18 TP_ARGS(sk, size),
26 __field(__u16, size)
52 __entry->size = size;
71 __entry->saddr, __entry->daddr, __entry->size,
/net/tls/
Dtls_sw.c313 len = required - msg_pl->sg.size; in tls_clone_plaintext_msg()
318 skip = prot->prepend_size + msg_pl->sg.size; in tls_clone_plaintext_msg()
562 u32 orig_size = msg_opl->sg.size; in tls_split_open_record()
571 ret = sk_msg_alloc(sk, &new->msg_encrypted, msg_opl->sg.size + in tls_split_open_record()
606 msg_opl->sg.size = bytes; in tls_split_open_record()
610 msg_npl->sg.size = orig_size - bytes; in tls_split_open_record()
664 msg_opl->apply_bytes = msg_opl->sg.size + msg_npl->sg.size; in tls_merge_open_record()
665 msg_opl->sg.size += msg_npl->sg.size; in tls_merge_open_record()
693 split = split_point && split_point < msg_pl->sg.size; in tls_push_record()
695 msg_pl->sg.size + in tls_push_record()
[all …]
/net/xdp/
Dxsk_queue.c12 void xskq_set_umem(struct xsk_queue *q, u64 size, u64 chunk_mask) in xskq_set_umem() argument
17 q->size = size; in xskq_set_umem()
35 size_t size; in xskq_create() local
46 size = umem_queue ? xskq_umem_get_ring_size(q) : in xskq_create()
50 get_order(size)); in xskq_create()

12345678910>>...14