Home
last modified time | relevance | path

Searched refs:pfrag (Results 1 – 18 of 18) sorted by relevance

/Linux-v5.4/net/tls/
Dtls_device.c233 struct page_frag *pfrag, in tls_append_frag() argument
239 if (skb_frag_page(frag) == pfrag->page && in tls_append_frag()
240 skb_frag_off(frag) + skb_frag_size(frag) == pfrag->offset) { in tls_append_frag()
244 __skb_frag_set_page(frag, pfrag->page); in tls_append_frag()
245 skb_frag_off_set(frag, pfrag->offset); in tls_append_frag()
248 get_page(pfrag->page); in tls_append_frag()
251 pfrag->offset += size; in tls_append_frag()
292 struct page_frag *pfrag, in tls_device_record_close() argument
304 if (likely(skb_page_frag_refill(prot->tag_size, pfrag, in tls_device_record_close()
307 tls_append_frag(record, pfrag, prot->tag_size); in tls_device_record_close()
[all …]
/Linux-v5.4/net/ipv6/
Desp6.c246 struct page_frag *pfrag = &x->xfrag; in esp6_output_head() local
254 if (unlikely(!skb_page_frag_refill(allocsize, pfrag, GFP_ATOMIC))) { in esp6_output_head()
259 page = pfrag->page; in esp6_output_head()
264 tail = vaddr + pfrag->offset; in esp6_output_head()
272 __skb_fill_page_desc(skb, nfrags, page, pfrag->offset, in esp6_output_head()
276 pfrag->offset = pfrag->offset + allocsize; in esp6_output_head()
360 struct page_frag *pfrag = &x->xfrag; in esp6_output_tail() local
365 if (unlikely(!skb_page_frag_refill(allocsize, pfrag, GFP_ATOMIC))) { in esp6_output_tail()
372 page = pfrag->page; in esp6_output_tail()
375 __skb_fill_page_desc(skb, 0, page, pfrag->offset, skb->data_len); in esp6_output_tail()
[all …]
Dip6_output.c1317 struct page_frag *pfrag, in __ip6_append_data() argument
1606 if (!sk_page_frag_refill(sk, pfrag)) in __ip6_append_data()
1609 if (!skb_can_coalesce(skb, i, pfrag->page, in __ip6_append_data()
1610 pfrag->offset)) { in __ip6_append_data()
1615 __skb_fill_page_desc(skb, i, pfrag->page, in __ip6_append_data()
1616 pfrag->offset, 0); in __ip6_append_data()
1618 get_page(pfrag->page); in __ip6_append_data()
1620 copy = min_t(int, copy, pfrag->size - pfrag->offset); in __ip6_append_data()
1622 page_address(pfrag->page) + pfrag->offset, in __ip6_append_data()
1626 pfrag->offset += copy; in __ip6_append_data()
/Linux-v5.4/net/ipv4/
Desp4.c301 struct page_frag *pfrag = &x->xfrag; in esp_output_head() local
309 if (unlikely(!skb_page_frag_refill(allocsize, pfrag, GFP_ATOMIC))) { in esp_output_head()
314 page = pfrag->page; in esp_output_head()
319 tail = vaddr + pfrag->offset; in esp_output_head()
327 __skb_fill_page_desc(skb, nfrags, page, pfrag->offset, in esp_output_head()
331 pfrag->offset = pfrag->offset + allocsize; in esp_output_head()
419 struct page_frag *pfrag = &x->xfrag; in esp_output_tail() local
424 if (unlikely(!skb_page_frag_refill(allocsize, pfrag, GFP_ATOMIC))) { in esp_output_tail()
431 page = pfrag->page; in esp_output_tail()
434 __skb_fill_page_desc(skb, 0, page, pfrag->offset, skb->data_len); in esp_output_tail()
[all …]
Dip_output.c957 struct page_frag *pfrag, in __ip_append_data() argument
1185 if (!sk_page_frag_refill(sk, pfrag)) in __ip_append_data()
1188 if (!skb_can_coalesce(skb, i, pfrag->page, in __ip_append_data()
1189 pfrag->offset)) { in __ip_append_data()
1194 __skb_fill_page_desc(skb, i, pfrag->page, in __ip_append_data()
1195 pfrag->offset, 0); in __ip_append_data()
1197 get_page(pfrag->page); in __ip_append_data()
1199 copy = min_t(int, copy, pfrag->size - pfrag->offset); in __ip_append_data()
1201 page_address(pfrag->page) + pfrag->offset, in __ip_append_data()
1205 pfrag->offset += copy; in __ip_append_data()
Dtcp.c1318 struct page_frag *pfrag = sk_page_frag(sk); in tcp_sendmsg_locked() local
1320 if (!sk_page_frag_refill(sk, pfrag)) in tcp_sendmsg_locked()
1323 if (!skb_can_coalesce(skb, i, pfrag->page, in tcp_sendmsg_locked()
1324 pfrag->offset)) { in tcp_sendmsg_locked()
1332 copy = min_t(int, copy, pfrag->size - pfrag->offset); in tcp_sendmsg_locked()
1338 pfrag->page, in tcp_sendmsg_locked()
1339 pfrag->offset, in tcp_sendmsg_locked()
1348 skb_fill_page_desc(skb, i, pfrag->page, in tcp_sendmsg_locked()
1349 pfrag->offset, copy); in tcp_sendmsg_locked()
1350 page_ref_inc(pfrag->page); in tcp_sendmsg_locked()
[all …]
/Linux-v5.4/net/core/
Dskmsg.c28 struct page_frag *pfrag = sk_page_frag(sk); in sk_msg_alloc() local
37 if (!sk_page_frag_refill(sk, pfrag)) in sk_msg_alloc()
40 orig_offset = pfrag->offset; in sk_msg_alloc()
41 use = min_t(int, len, pfrag->size - orig_offset); in sk_msg_alloc()
50 sg_page(sge) == pfrag->page && in sk_msg_alloc()
61 sg_set_page(sge, pfrag->page, use, orig_offset); in sk_msg_alloc()
62 get_page(pfrag->page); in sk_msg_alloc()
68 pfrag->offset += use; in sk_msg_alloc()
Dsock.c2360 bool skb_page_frag_refill(unsigned int sz, struct page_frag *pfrag, gfp_t gfp) in skb_page_frag_refill() argument
2362 if (pfrag->page) { in skb_page_frag_refill()
2363 if (page_ref_count(pfrag->page) == 1) { in skb_page_frag_refill()
2364 pfrag->offset = 0; in skb_page_frag_refill()
2367 if (pfrag->offset + sz <= pfrag->size) in skb_page_frag_refill()
2369 put_page(pfrag->page); in skb_page_frag_refill()
2372 pfrag->offset = 0; in skb_page_frag_refill()
2376 pfrag->page = alloc_pages((gfp & ~__GFP_DIRECT_RECLAIM) | in skb_page_frag_refill()
2380 if (likely(pfrag->page)) { in skb_page_frag_refill()
2381 pfrag->size = PAGE_SIZE << SKB_FRAG_PAGE_ORDER; in skb_page_frag_refill()
[all …]
Dskbuff.c2279 struct page_frag *pfrag = sk_page_frag(sk); in linear_to_page() local
2281 if (!sk_page_frag_refill(sk, pfrag)) in linear_to_page()
2284 *len = min_t(unsigned int, *len, pfrag->size - pfrag->offset); in linear_to_page()
2286 memcpy(page_address(pfrag->page) + pfrag->offset, in linear_to_page()
2288 *offset = pfrag->offset; in linear_to_page()
2289 pfrag->offset += *len; in linear_to_page()
2291 return pfrag->page; in linear_to_page()
/Linux-v5.4/drivers/vhost/
Dnet.c646 struct page_frag *pfrag, gfp_t gfp) in vhost_net_page_frag_refill() argument
648 if (pfrag->page) { in vhost_net_page_frag_refill()
649 if (pfrag->offset + sz <= pfrag->size) in vhost_net_page_frag_refill()
651 __page_frag_cache_drain(pfrag->page, net->refcnt_bias); in vhost_net_page_frag_refill()
654 pfrag->offset = 0; in vhost_net_page_frag_refill()
658 pfrag->page = alloc_pages((gfp & ~__GFP_DIRECT_RECLAIM) | in vhost_net_page_frag_refill()
662 if (likely(pfrag->page)) { in vhost_net_page_frag_refill()
663 pfrag->size = PAGE_SIZE << SKB_FRAG_PAGE_ORDER; in vhost_net_page_frag_refill()
667 pfrag->page = alloc_page(gfp); in vhost_net_page_frag_refill()
668 if (likely(pfrag->page)) { in vhost_net_page_frag_refill()
[all …]
/Linux-v5.4/net/kcm/
Dkcmsock.c959 struct page_frag *pfrag = sk_page_frag(sk); in kcm_sendmsg() local
961 if (!sk_page_frag_refill(sk, pfrag)) in kcm_sendmsg()
964 if (!skb_can_coalesce(skb, i, pfrag->page, in kcm_sendmsg()
965 pfrag->offset)) { in kcm_sendmsg()
986 pfrag->size - pfrag->offset); in kcm_sendmsg()
992 pfrag->page, in kcm_sendmsg()
993 pfrag->offset, in kcm_sendmsg()
1002 skb_fill_page_desc(skb, i, pfrag->page, in kcm_sendmsg()
1003 pfrag->offset, copy); in kcm_sendmsg()
1004 get_page(pfrag->page); in kcm_sendmsg()
[all …]
/Linux-v5.4/drivers/net/ethernet/mellanox/mlx4/
Den_tx.c564 void **pfrag) in is_inline() argument
575 *pfrag = ptr; in is_inline()
599 void **pfrag) in get_real_size() argument
626 shinfo, pfrag); in get_real_size()
/Linux-v5.4/fs/ceph/
Dinode.c180 struct ceph_inode_frag *pfrag, int *found) in __ceph_choose_frag() argument
196 if (pfrag) in __ceph_choose_frag()
197 memcpy(pfrag, frag, sizeof(*pfrag)); in __ceph_choose_frag()
222 struct ceph_inode_frag *pfrag, int *found) in ceph_choose_frag() argument
226 ret = __ceph_choose_frag(ci, v, pfrag, found); in ceph_choose_frag()
Dsuper.h618 struct ceph_inode_frag *pfrag,
/Linux-v5.4/drivers/scsi/be2iscsi/
Dbe_main.c2121 psgl = (struct iscsi_sge *)io_task->psgl_handle->pfrag; in hwi_write_sgl_v2()
2210 psgl = (struct iscsi_sge *)io_task->psgl_handle->pfrag; in hwi_write_sgl()
2313 psgl = (struct iscsi_sge *)io_task->psgl_handle->pfrag; in hwi_write_buffer()
3884 struct iscsi_sge *pfrag; in beiscsi_init_sgl_handle() local
3962 pfrag = mem_descr_sg->mem_array[idx].virtual_address; in beiscsi_init_sgl_handle()
3973 psgl_handle->pfrag = pfrag; in beiscsi_init_sgl_handle()
3974 AMAP_SET_BITS(struct amap_iscsi_sge, addr_hi, pfrag, 0); in beiscsi_init_sgl_handle()
3975 AMAP_SET_BITS(struct amap_iscsi_sge, addr_lo, pfrag, 0); in beiscsi_init_sgl_handle()
3976 pfrag += phba->params.num_sge_per_io; in beiscsi_init_sgl_handle()
Dbe_main.h213 struct iscsi_sge *pfrag; member
/Linux-v5.4/include/net/
Dsock.h2261 bool sk_page_frag_refill(struct sock *sk, struct page_frag *pfrag);
/Linux-v5.4/include/linux/
Dskbuff.h3052 bool skb_page_frag_refill(unsigned int sz, struct page_frag *pfrag, gfp_t prio);