search for: is_rx

Displaying 8 results from an estimated 8 matches for "is_rx".

2017 Jan 22
2
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...st struct sk_buff *skb, >> struct virtio_net_hdr *hdr, >> - bool little_endian) >> + bool little_endian, >> + bool has_data_valid) >> { >> memset(hdr, 0, sizeof(*hdr)); /* no info leak */ >> > I would prefer naming it is_rx. Callers should not know about > internal details like data valid, the issue we are trying to fix > here is that tx and tx headers are slightly different. > Actually, I've considered something like this, but the problem is: - tun use this on xmit, so is_rx = true may cause some confu...
2017 Jan 22
2
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...st struct sk_buff *skb, >> struct virtio_net_hdr *hdr, >> - bool little_endian) >> + bool little_endian, >> + bool has_data_valid) >> { >> memset(hdr, 0, sizeof(*hdr)); /* no info leak */ >> > I would prefer naming it is_rx. Callers should not know about > internal details like data valid, the issue we are trying to fix > here is that tx and tx headers are slightly different. > Actually, I've considered something like this, but the problem is: - tun use this on xmit, so is_rx = true may cause some confu...
2017 Jan 22
0
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...> > struct virtio_net_hdr *hdr, > > > - bool little_endian) > > > + bool little_endian, > > > + bool has_data_valid) > > > { > > > memset(hdr, 0, sizeof(*hdr)); /* no info leak */ > > I would prefer naming it is_rx. Callers should not know about > > internal details like data valid, the issue we are trying to fix > > here is that tx and tx headers are slightly different. > > > > Actually, I've considered something like this, but the problem is: > > - tun use this on xmit,...
2017 Jan 20
4
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
Commit 501db511397f ("virtio: don't set VIRTIO_NET_HDR_F_DATA_VALID on xmit") in fact disables VIRTIO_HDR_F_DATA_VALID on receiving path too, fixing this by adding a hint (has_data_valid) and set it only on the receiving path. Cc: Rolf Neugebauer <rolf.neugebauer at docker.com> Signed-off-by: Jason Wang <jasowang at redhat.com> --- drivers/net/macvtap.c | 2 +-
2017 Jan 20
4
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
Commit 501db511397f ("virtio: don't set VIRTIO_NET_HDR_F_DATA_VALID on xmit") in fact disables VIRTIO_HDR_F_DATA_VALID on receiving path too, fixing this by adding a hint (has_data_valid) and set it only on the receiving path. Cc: Rolf Neugebauer <rolf.neugebauer at docker.com> Signed-off-by: Jason Wang <jasowang at redhat.com> --- drivers/net/macvtap.c | 2 +-
2017 Jan 20
0
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...line int virtio_net_hdr_from_skb(const struct sk_buff *skb, > struct virtio_net_hdr *hdr, > - bool little_endian) > + bool little_endian, > + bool has_data_valid) > { > memset(hdr, 0, sizeof(*hdr)); /* no info leak */ > I would prefer naming it is_rx. Callers should not know about internal details like data valid, the issue we are trying to fix here is that tx and tx headers are slightly different. > @@ -91,6 +92,9 @@ static inline int virtio_net_hdr_from_skb(const struct sk_buff *skb, > skb_checksum_start_offset(skb)); > hdr...
2020 Apr 06
2
[PATCH v2 1/2] virtio: stop using legacy struct vring
...tqueue_get_vring(vring->vq); struct virtio_device *vdev = &cons->vdev; u32 len, idx, seg; void *addr; @@ -671,7 +671,7 @@ static void mlxbf_tmfifo_rxtx_header(struct mlxbf_tmfifo_vring *vring, static bool mlxbf_tmfifo_rxtx_one_desc(struct mlxbf_tmfifo_vring *vring, bool is_rx, int *avail) { - const struct vring *vr = virtqueue_get_vring(vring->vq); + const struct vring_s *vr = virtqueue_get_vring(vring->vq); struct mlxbf_tmfifo *fifo = vring->fifo; struct virtio_device *vdev; bool vring_change = false; diff --git a/drivers/virtio/virtio_ring.c b/drivers/...
2020 Apr 06
2
[PATCH v2 1/2] virtio: stop using legacy struct vring
...tqueue_get_vring(vring->vq); struct virtio_device *vdev = &cons->vdev; u32 len, idx, seg; void *addr; @@ -671,7 +671,7 @@ static void mlxbf_tmfifo_rxtx_header(struct mlxbf_tmfifo_vring *vring, static bool mlxbf_tmfifo_rxtx_one_desc(struct mlxbf_tmfifo_vring *vring, bool is_rx, int *avail) { - const struct vring *vr = virtqueue_get_vring(vring->vq); + const struct vring_s *vr = virtqueue_get_vring(vring->vq); struct mlxbf_tmfifo *fifo = vring->fifo; struct virtio_device *vdev; bool vring_change = false; diff --git a/drivers/virtio/virtio_ring.c b/drivers/...