Displaying 20 results from an estimated 54 matches for "out_pkt".
Did you mean:
out_path
2018 Dec 12
4
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...;
if (!pkt)
@@ -62,12 +63,16 @@ static const struct virtio_transport *virtio_transport_get_ops(void)
pkt->vsk = info->vsk;
if (info->msg && len > 0) {
- pkt->buf = kmalloc(len, GFP_KERNEL);
- if (!pkt->buf)
+ buf = kmalloc(len, GFP_KERNEL);
+ if (!buf)
goto out_pkt;
- err = memcpy_from_msg(pkt->buf, info->msg, len);
+ err = memcpy_from_msg(buf, info->msg, len);
if (err)
goto out;
+
+ pkt->vec[0].iov_base = buf;
+ pkt->vec[0].iov_len = len;
+ pkt->nr_vecs = 1;
}
trace_virtio_transport_alloc_pkt(src_cid, src_port,
@@ -80,7 +85...
2018 Dec 12
4
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...;
if (!pkt)
@@ -62,12 +63,16 @@ static const struct virtio_transport *virtio_transport_get_ops(void)
pkt->vsk = info->vsk;
if (info->msg && len > 0) {
- pkt->buf = kmalloc(len, GFP_KERNEL);
- if (!pkt->buf)
+ buf = kmalloc(len, GFP_KERNEL);
+ if (!buf)
goto out_pkt;
- err = memcpy_from_msg(pkt->buf, info->msg, len);
+ err = memcpy_from_msg(buf, info->msg, len);
if (err)
goto out;
+
+ pkt->vec[0].iov_base = buf;
+ pkt->vec[0].iov_len = len;
+ pkt->nr_vecs = 1;
}
trace_virtio_transport_alloc_pkt(src_cid, src_port,
@@ -80,7 +85...
2018 Dec 13
2
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...*virtio_transport_get_ops(void)
>> pkt->vsk = info->vsk;
>>
>> if (info->msg && len > 0) {
>> - pkt->buf = kmalloc(len, GFP_KERNEL);
>> - if (!pkt->buf)
>> + buf = kmalloc(len, GFP_KERNEL);
>> + if (!buf)
>> goto out_pkt;
>> - err = memcpy_from_msg(pkt->buf, info->msg, len);
>> + err = memcpy_from_msg(buf, info->msg, len);
>> if (err)
>> goto out;
>> +
>> + pkt->vec[0].iov_base = buf;
>> + pkt->vec[0].iov_len = len;
>> + pkt->nr_vecs = 1;...
2018 Dec 13
2
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...*virtio_transport_get_ops(void)
>> pkt->vsk = info->vsk;
>>
>> if (info->msg && len > 0) {
>> - pkt->buf = kmalloc(len, GFP_KERNEL);
>> - if (!pkt->buf)
>> + buf = kmalloc(len, GFP_KERNEL);
>> + if (!buf)
>> goto out_pkt;
>> - err = memcpy_from_msg(pkt->buf, info->msg, len);
>> + err = memcpy_from_msg(buf, info->msg, len);
>> if (err)
>> goto out;
>> +
>> + pkt->vec[0].iov_base = buf;
>> + pkt->vec[0].iov_len = len;
>> + pkt->nr_vecs = 1;...
2019 May 14
3
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...ck/virtio_transport_common.c
>>> +++ b/net/vmw_vsock/virtio_transport_common.c
>>> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
>>> pkt->buf = kmalloc(len, GFP_KERNEL);
>>> if (!pkt->buf)
>>> goto out_pkt;
>>> +
>>> + pkt->buf_len = len;
>>> +
>>> err = memcpy_from_msg(pkt->buf, info->msg, len);
>>> if (err)
>>> goto out;
>>> @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
>&...
2019 May 14
3
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...ck/virtio_transport_common.c
>>> +++ b/net/vmw_vsock/virtio_transport_common.c
>>> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
>>> pkt->buf = kmalloc(len, GFP_KERNEL);
>>> if (!pkt->buf)
>>> goto out_pkt;
>>> +
>>> + pkt->buf_len = len;
>>> +
>>> err = memcpy_from_msg(pkt->buf, info->msg, len);
>>> if (err)
>>> goto out;
>>> @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
>&...
2019 May 13
2
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
....0248d6808755 100644
> --- a/net/vmw_vsock/virtio_transport_common.c
> +++ b/net/vmw_vsock/virtio_transport_common.c
> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> pkt->buf = kmalloc(len, GFP_KERNEL);
> if (!pkt->buf)
> goto out_pkt;
> +
> + pkt->buf_len = len;
> +
> err = memcpy_from_msg(pkt->buf, info->msg, len);
> if (err)
> goto out;
> @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> return NULL;
> }
>
> +static struct virtio...
2019 May 13
2
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
....0248d6808755 100644
> --- a/net/vmw_vsock/virtio_transport_common.c
> +++ b/net/vmw_vsock/virtio_transport_common.c
> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> pkt->buf = kmalloc(len, GFP_KERNEL);
> if (!pkt->buf)
> goto out_pkt;
> +
> + pkt->buf_len = len;
> +
> err = memcpy_from_msg(pkt->buf, info->msg, len);
> if (err)
> goto out;
> @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> return NULL;
> }
>
> +static struct virtio...
2018 Dec 12
0
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...const struct virtio_transport *virtio_transport_get_ops(void)
> pkt->vsk = info->vsk;
>
> if (info->msg && len > 0) {
> - pkt->buf = kmalloc(len, GFP_KERNEL);
> - if (!pkt->buf)
> + buf = kmalloc(len, GFP_KERNEL);
> + if (!buf)
> goto out_pkt;
> - err = memcpy_from_msg(pkt->buf, info->msg, len);
> + err = memcpy_from_msg(buf, info->msg, len);
> if (err)
> goto out;
> +
> + pkt->vec[0].iov_base = buf;
> + pkt->vec[0].iov_len = len;
> + pkt->nr_vecs = 1;
> }
>
> trace_vir...
2018 Dec 13
0
[PATCH v2 3/5] VSOCK: support receive mergeable rx buffer in guest
...;> pkt->vsk = info->vsk;
> >>
> >> if (info->msg && len > 0) {
> >> - pkt->buf = kmalloc(len, GFP_KERNEL);
> >> - if (!pkt->buf)
> >> + buf = kmalloc(len, GFP_KERNEL);
> >> + if (!buf)
> >> goto out_pkt;
> >> - err = memcpy_from_msg(pkt->buf, info->msg, len);
> >> + err = memcpy_from_msg(buf, info->msg, len);
> >> if (err)
> >> goto out;
> >> +
> >> + pkt->vec[0].iov_base = buf;
> >> + pkt->vec[0].iov_len = le...
2019 May 12
1
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...75..0248d6808755 100644
> --- a/net/vmw_vsock/virtio_transport_common.c
> +++ b/net/vmw_vsock/virtio_transport_common.c
> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> pkt->buf = kmalloc(len, GFP_KERNEL);
> if (!pkt->buf)
> goto out_pkt;
> +
> + pkt->buf_len = len;
> +
> err = memcpy_from_msg(pkt->buf, info->msg, len);
> if (err)
> goto out;
> @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> return NULL;
> }
>
> +static struct virtio_vsock...
2019 May 31
0
[PATCH v3 1/5] vsock/virtio: limit the memory used per-socket
...N 128
+
static const struct virtio_transport *virtio_transport_get_ops(void)
{
const struct vsock_transport *t = vsock_core_get_transport();
@@ -65,6 +68,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
pkt->buf = kmalloc(len, GFP_KERNEL);
if (!pkt->buf)
goto out_pkt;
+
+ pkt->buf_len = len;
+
err = memcpy_from_msg(pkt->buf, info->msg, len);
if (err)
goto out;
@@ -842,24 +848,60 @@ virtio_transport_recv_connecting(struct sock *sk,
return err;
}
+static void
+virtio_transport_recv_enqueue(struct vsock_sock *vsk,
+ struct virtio_v...
2019 Jul 17
0
[PATCH v4 1/5] vsock/virtio: limit the memory used per-socket
...N 128
+
static const struct virtio_transport *virtio_transport_get_ops(void)
{
const struct vsock_transport *t = vsock_core_get_transport();
@@ -64,6 +67,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
pkt->buf = kmalloc(len, GFP_KERNEL);
if (!pkt->buf)
goto out_pkt;
+
+ pkt->buf_len = len;
+
err = memcpy_from_msg(pkt->buf, info->msg, len);
if (err)
goto out;
@@ -841,24 +847,60 @@ virtio_transport_recv_connecting(struct sock *sk,
return err;
}
+static void
+virtio_transport_recv_enqueue(struct vsock_sock *vsk,
+ struct virtio_v...
2019 May 13
0
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...--- a/net/vmw_vsock/virtio_transport_common.c
> > +++ b/net/vmw_vsock/virtio_transport_common.c
> > @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> > pkt->buf = kmalloc(len, GFP_KERNEL);
> > if (!pkt->buf)
> > goto out_pkt;
> > +
> > + pkt->buf_len = len;
> > +
> > err = memcpy_from_msg(pkt->buf, info->msg, len);
> > if (err)
> > goto out;
> > @@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> > return NULL;
>...
2019 May 14
0
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...gt; > > +++ b/net/vmw_vsock/virtio_transport_common.c
> > > > @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
> > > > pkt->buf = kmalloc(len, GFP_KERNEL);
> > > > if (!pkt->buf)
> > > > goto out_pkt;
> > > > +
> > > > + pkt->buf_len = len;
> > > > +
> > > > err = memcpy_from_msg(pkt->buf, info->msg, len);
> > > > if (err)
> > > > goto out;
> > > > @@ -86,6 +89,46 @@ virtio_transport_al...
2019 May 10
0
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...port_common.c
index 602715fc9a75..0248d6808755 100644
--- a/net/vmw_vsock/virtio_transport_common.c
+++ b/net/vmw_vsock/virtio_transport_common.c
@@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
pkt->buf = kmalloc(len, GFP_KERNEL);
if (!pkt->buf)
goto out_pkt;
+
+ pkt->buf_len = len;
+
err = memcpy_from_msg(pkt->buf, info->msg, len);
if (err)
goto out;
@@ -86,6 +89,46 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
return NULL;
}
+static struct virtio_vsock_buf *
+virtio_transport_alloc_buf(struct virtio_vsock_...
2013 Jun 27
1
[RFC 2/5] VSOCK: Introduce virtio-vsock-common.ko
...hdr.dst_port = dst_port;
> + pkt->hdr.len = len;
> + pkt->hdr.shut = info->shut;
> + pkt->len = len;
> + pkt->trans = trans;
> +
> + if (info->iov && len > 0) {
> + pkt->buf = kmalloc(len, GFP_KERNEL);
> + if (!pkt->buf)
> + goto out_pkt;
> + err = memcpy_fromiovec(pkt->buf, info->iov, len);
> + if (err)
> + goto out;
> + }
> +
> + return pkt;
> +
> +out:
> + kfree(pkt->buf);
> +out_pkt:
> + kfree(pkt);
> + return NULL;
> +}
> +EXPORT_SYMBOL_GPL(virtio_transport_alloc_pkt);
>...
2013 Jun 27
1
[RFC 2/5] VSOCK: Introduce virtio-vsock-common.ko
...hdr.dst_port = dst_port;
> + pkt->hdr.len = len;
> + pkt->hdr.shut = info->shut;
> + pkt->len = len;
> + pkt->trans = trans;
> +
> + if (info->iov && len > 0) {
> + pkt->buf = kmalloc(len, GFP_KERNEL);
> + if (!pkt->buf)
> + goto out_pkt;
> + err = memcpy_fromiovec(pkt->buf, info->iov, len);
> + if (err)
> + goto out;
> + }
> +
> + return pkt;
> +
> +out:
> + kfree(pkt->buf);
> +out_pkt:
> + kfree(pkt);
> + return NULL;
> +}
> +EXPORT_SYMBOL_GPL(virtio_transport_alloc_pkt);
>...
2015 Dec 09
0
[PATCH v3 1/4] VSOCK: Introduce virtio-vsock-common.ko
...>hdr.dst_port = cpu_to_le32(dst_port);
+ pkt->hdr.flags = cpu_to_le32(info->flags);
+ pkt->len = len;
+ pkt->trans = trans;
+ pkt->hdr.len = cpu_to_le32(len);
+
+ if (info->msg && len > 0) {
+ pkt->buf = kmalloc(len, GFP_KERNEL);
+ if (!pkt->buf)
+ goto out_pkt;
+ err = memcpy_from_msg(pkt->buf, info->msg, len);
+ if (err)
+ goto out;
+ }
+
+ return pkt;
+
+out:
+ kfree(pkt->buf);
+out_pkt:
+ kfree(pkt);
+ return NULL;
+}
+EXPORT_SYMBOL_GPL(virtio_transport_alloc_pkt);
+
+struct sock *
+virtio_transport_get_pending(struct sock *listener,
+...
2019 May 15
2
[PATCH v2 1/8] vsock/virtio: limit the memory used per-socket
...t;> +++ b/net/vmw_vsock/virtio_transport_common.c
>>>>> @@ -65,6 +65,9 @@ virtio_transport_alloc_pkt(struct virtio_vsock_pkt_info *info,
>>>>> pkt->buf = kmalloc(len, GFP_KERNEL);
>>>>> if (!pkt->buf)
>>>>> goto out_pkt;
>>>>> +
>>>>> + pkt->buf_len = len;
>>>>> +
>>>>> err = memcpy_from_msg(pkt->buf, info->msg, len);
>>>>> if (err)
>>>>> goto out;
>>>>> @@ -86,6 +89,46 @@ virtio_tr...