vhost: fix log for async dequeue

Message ID 20220617054003.1291251-1-david.marchand@redhat.com (mailing list archive)
State Accepted, archived
Delegated to: Maxime Coquelin
Headers
Series vhost: fix log for async dequeue |

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK
ci/intel-Testing success Testing PASS
ci/iol-mellanox-Performance success Performance Testing PASS
ci/iol-aarch64-unit-testing success Testing PASS
ci/github-robot: build success github build: passed
ci/iol-aarch64-compile-testing success Testing PASS
ci/iol-x86_64-compile-testing success Testing PASS
ci/iol-x86_64-unit-testing success Testing PASS
ci/iol-intel-Performance success Performance Testing PASS
ci/iol-intel-Functional success Functional Testing PASS
ci/iol-abi-testing success Testing PASS

Commit Message

David Marchand June 17, 2022, 5:40 a.m. UTC
  Since the commit 02798b073520 ("vhost: improve virtio-net layer logs"),
vhost logs contain the socket path as a prefix.
Async dequeue path was copied from the sync dequeue path but a log
was incorrect.

Fixes: 84d5204310d7 ("vhost: support async dequeue for split ring")

Signed-off-by: David Marchand <david.marchand@redhat.com>
---
 lib/vhost/virtio_net.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
  

Comments

Maxime Coquelin June 17, 2022, 2 p.m. UTC | #1
On 6/17/22 07:40, David Marchand wrote:
> Since the commit 02798b073520 ("vhost: improve virtio-net layer logs"),
> vhost logs contain the socket path as a prefix.
> Async dequeue path was copied from the sync dequeue path but a log
> was incorrect.
> 
> Fixes: 84d5204310d7 ("vhost: support async dequeue for split ring")
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
>   lib/vhost/virtio_net.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
> index 68a26eb17d..bedd406b37 100644
> --- a/lib/vhost/virtio_net.c
> +++ b/lib/vhost/virtio_net.c
> @@ -3529,7 +3529,7 @@ rte_vhost_async_try_dequeue_burst(int vid, uint16_t queue_id,
>   
>   		rarp_mbuf = rte_net_make_rarp_packet(mbuf_pool, &dev->mac);
>   		if (rarp_mbuf == NULL) {
> -			VHOST_LOG_DATA(ERR, "Failed to make RARP packet.\n");
> +			VHOST_LOG_DATA(ERR, "(%s) failed to make RARP packet.\n", dev->ifname);
>   			count = 0;
>   			goto out;
>   		}

Reviewed-by: Maxime Coquelin <maxime.coquelin@redhat.com>

Thanks,
Maxime
  
Maxime Coquelin June 17, 2022, 2:09 p.m. UTC | #2
On 6/17/22 07:40, David Marchand wrote:
> Since the commit 02798b073520 ("vhost: improve virtio-net layer logs"),
> vhost logs contain the socket path as a prefix.
> Async dequeue path was copied from the sync dequeue path but a log
> was incorrect.
> 
> Fixes: 84d5204310d7 ("vhost: support async dequeue for split ring")
> 
> Signed-off-by: David Marchand <david.marchand@redhat.com>
> ---
>   lib/vhost/virtio_net.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 

Applied to dpdk-next-virtio/main.

Thanks,
Maxime
  

Patch

diff --git a/lib/vhost/virtio_net.c b/lib/vhost/virtio_net.c
index 68a26eb17d..bedd406b37 100644
--- a/lib/vhost/virtio_net.c
+++ b/lib/vhost/virtio_net.c
@@ -3529,7 +3529,7 @@  rte_vhost_async_try_dequeue_burst(int vid, uint16_t queue_id,
 
 		rarp_mbuf = rte_net_make_rarp_packet(mbuf_pool, &dev->mac);
 		if (rarp_mbuf == NULL) {
-			VHOST_LOG_DATA(ERR, "Failed to make RARP packet.\n");
+			VHOST_LOG_DATA(ERR, "(%s) failed to make RARP packet.\n", dev->ifname);
 			count = 0;
 			goto out;
 		}