* [dpdk-stable] [PATCH] net/virtio: zero the whole memory zone
@ 2017-06-12 4:34 Tiwei Bie
2017-06-12 10:21 ` Yuanhan Liu
2017-06-14 7:52 ` [dpdk-stable] [dpdk-dev] " Jens Freimann
0 siblings, 2 replies; 3+ messages in thread
From: Tiwei Bie @ 2017-06-12 4:34 UTC (permalink / raw)
To: dev; +Cc: yliu, maxime.coquelin, mtetsuyah, stable
Zero the whole memory zone instead of the first few bytes.
Fixes: c1f86306a026 ("virtio: add new driver")
Cc: stable@dpdk.org
Signed-off-by: Tiwei Bie <tiwei.bie@intel.com>
---
drivers/net/virtio/virtio_ethdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
index 45f9bca..88118f1 100644
--- a/drivers/net/virtio/virtio_ethdev.c
+++ b/drivers/net/virtio/virtio_ethdev.c
@@ -424,7 +424,7 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t vtpci_queue_idx)
}
}
- memset(mz->addr, 0, sizeof(mz->len));
+ memset(mz->addr, 0, mz->len);
vq->vq_ring_mem = mz->phys_addr;
vq->vq_ring_virt_mem = mz->addr;
--
2.7.4
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-stable] [PATCH] net/virtio: zero the whole memory zone
2017-06-12 4:34 [dpdk-stable] [PATCH] net/virtio: zero the whole memory zone Tiwei Bie
@ 2017-06-12 10:21 ` Yuanhan Liu
2017-06-14 7:52 ` [dpdk-stable] [dpdk-dev] " Jens Freimann
1 sibling, 0 replies; 3+ messages in thread
From: Yuanhan Liu @ 2017-06-12 10:21 UTC (permalink / raw)
To: Tiwei Bie; +Cc: dev, maxime.coquelin, mtetsuyah, stable
On Mon, Jun 12, 2017 at 12:34:30PM +0800, Tiwei Bie wrote:
> Zero the whole memory zone instead of the first few bytes.
>
> Fixes: c1f86306a026 ("virtio: add new driver")
> Cc: stable@dpdk.org
>
> Signed-off-by: Tiwei Bie <tiwei.bie@intel.com>
> ---
> drivers/net/virtio/virtio_ethdev.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/net/virtio/virtio_ethdev.c b/drivers/net/virtio/virtio_ethdev.c
> index 45f9bca..88118f1 100644
> --- a/drivers/net/virtio/virtio_ethdev.c
> +++ b/drivers/net/virtio/virtio_ethdev.c
> @@ -424,7 +424,7 @@ virtio_init_queue(struct rte_eth_dev *dev, uint16_t vtpci_queue_idx)
> }
> }
>
> - memset(mz->addr, 0, sizeof(mz->len));
> + memset(mz->addr, 0, mz->len);
Nice catch! Applied to dpdk-next-virtio.
Thanks.
--yliu
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [dpdk-stable] [dpdk-dev] [PATCH] net/virtio: zero the whole memory zone
2017-06-12 4:34 [dpdk-stable] [PATCH] net/virtio: zero the whole memory zone Tiwei Bie
2017-06-12 10:21 ` Yuanhan Liu
@ 2017-06-14 7:52 ` Jens Freimann
1 sibling, 0 replies; 3+ messages in thread
From: Jens Freimann @ 2017-06-14 7:52 UTC (permalink / raw)
To: Tiwei Bie; +Cc: dev, yliu, maxime.coquelin, mtetsuyah, stable
On Mon, Jun 12, 2017 at 12:34:30PM +0800, Tiwei Bie wrote:
> Zero the whole memory zone instead of the first few bytes.
>
> Fixes: c1f86306a026 ("virtio: add new driver")
> Cc: stable@dpdk.org
>
> Signed-off-by: Tiwei Bie <tiwei.bie@intel.com>
> ---
> drivers/net/virtio/virtio_ethdev.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
Reviewed-by: Jens Freimann <jfreimann@redhat.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2017-06-14 7:53 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-12 4:34 [dpdk-stable] [PATCH] net/virtio: zero the whole memory zone Tiwei Bie
2017-06-12 10:21 ` Yuanhan Liu
2017-06-14 7:52 ` [dpdk-stable] [dpdk-dev] " Jens Freimann
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).