[dpdk-stable] patch 'vhost: fix message payload union in setting ring address' has been queued to stable release 18.02.2

luca.boccassi at gmail.com luca.boccassi at gmail.com
Mon Apr 30 16:03:13 CEST 2018


Hi,

FYI, your patch has been queued to stable release 18.02.2

Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
It will be pushed if I get no objections before 05/02/18. So please
shout if anyone has objections.

Thanks.

Luca Boccassi

---
>From cfc4a715578e355c7b09104a79fd0af3ed309b54 Mon Sep 17 00:00:00 2001
From: Stefan Hajnoczi <stefanha at redhat.com>
Date: Mon, 5 Feb 2018 13:16:00 +0100
Subject: [PATCH] vhost: fix message payload union in setting ring address

[ upstream commit 55659ed3ed1880beef6211d345c5bb5baf5b4e8b ]

vhost_user_set_vring_addr() uses the msg->payload.addr union member, not
msg->payload.state.  Luckily the offset of the 'index' field is
identical in both structs, so there was never any buggy behavior.

Fixes: 5cd690e4fda9 ("vhost: fix vring addresses not translated")

Signed-off-by: Stefan Hajnoczi <stefanha at redhat.com>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
---
 lib/librte_vhost/vhost_user.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c
index 2d008fb02..dc282cb9f 100644
--- a/lib/librte_vhost/vhost_user.c
+++ b/lib/librte_vhost/vhost_user.c
@@ -513,7 +513,7 @@ vhost_user_set_vring_addr(struct virtio_net **pdev, VhostUserMsg *msg)
 
 	if (vq->enabled && (dev->features &
 				(1ULL << VHOST_USER_F_PROTOCOL_FEATURES))) {
-		dev = translate_ring_addresses(dev, msg->payload.state.index);
+		dev = translate_ring_addresses(dev, msg->payload.addr.index);
 		if (!dev)
 			return -1;
 
-- 
2.14.2



More information about the stable mailing list