search for: virtio_vsock_skb_headroom

Displaying 4 results from an estimated 4 matches for "virtio_vsock_skb_headroom".

2023 Feb 16
0
[RFC PATCH v1 07/12] vsock/virtio: MGS_ZEROCOPY flag support
...a negative errno. >@@ -47,15 +210,31 @@ virtio_transport_alloc_skb(struct virtio_vsock_pkt_info *info, > u32 src_cid, > u32 src_port, > u32 dst_cid, >- u32 dst_port) >+ u32 dst_port, >+ struct vsock_sock *vsk) > { >- const size_t skb_len = VIRTIO_VSOCK_SKB_HEADROOM + len; >+ const size_t skb_len = VIRTIO_VSOCK_SKB_HEADROOM; > struct virtio_vsock_hdr *hdr; > struct sk_buff *skb; >- void *payload; >- int err; >+ bool use_zcopy = false; >+ >+ if (info->msg) { >+ /* If SOCK_ZEROCOPY is not enabled, ignore MSG_ZEROCOPY >+ * fl...
2023 Aug 01
0
[PATCH net-next v5 4/4] vsock/virtio: MSG_ZEROCOPY flag support
...; + struct virtio_vsock_pkt_info *info, > + size_t payload_len, > + bool zcopy, > + u32 src_cid, > + u32 src_port, > + u32 dst_cid, > + u32 dst_port) > +{ > + struct sk_buff *skb; > + size_t skb_len; > + > + skb_len = VIRTIO_VSOCK_SKB_HEADROOM; > + > + if (!zcopy) > + skb_len += payload_len; > + > + skb = virtio_vsock_alloc_skb(skb_len, GFP_KERNEL); > + if (!skb) > + return NULL; > + > + virtio_transport_init_hdr(skb, info, src_cid, src_port, > + dst_cid, dst_port, > + payload_len); > + &gt...
2023 Aug 01
0
[PATCH net-next v5 4/4] vsock/virtio: MSG_ZEROCOPY flag support
...bool zcopy, > > > + u32 src_cid, > > > + u32 src_port, > > > + u32 dst_cid, > > > + u32 dst_port) > > > +{ > > > + struct sk_buff *skb; > > > + size_t skb_len; > > > + > > > + skb_len = VIRTIO_VSOCK_SKB_HEADROOM; > > > + > > > + if (!zcopy) > > > + skb_len += payload_len; > > > + > > > + skb = virtio_vsock_alloc_skb(skb_len, GFP_KERNEL); > > > + if (!skb) > > > + return NULL; > > > + > > > + virtio_transport_init_hdr(skb, in...
2023 Sep 04
0
[PATCH net-next v7 4/4] vsock/virtio: MSG_ZEROCOPY flag support
...ct virtio_vsock_pkt_info *info, >>> -?????????????? size_t len, >>> -?????????????? u32 src_cid, >>> -?????????????? u32 src_port, >>> -?????????????? u32 dst_cid, >>> -?????????????? u32 dst_port) >>> -{ >>> -??? const size_t skb_len = VIRTIO_VSOCK_SKB_HEADROOM + len; >>> -??? struct virtio_vsock_hdr *hdr; >>> -??? struct sk_buff *skb; >>> +static bool virtio_transport_can_zcopy(struct virtio_vsock_pkt_info *info, >>> +?????????????????????? size_t max_to_send) >> ????????????????????????????????????????????? ^ &g...