This patch fixes a bug found in port_flow_query routine which caused
flow query command to fail with the following error "Caught error
type 1 (cause unspecified): unknown object type to retrieve the name
of: Invalid argument".

Fixes: f7ba5e7a0f8c ("app/testpmd: rely on flow API conversion function")

Signed-off-by: Moti Haimovsky <mo...@mellanox.com>
---
 app/test-pmd/config.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index 009c92c..b11317b 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -1239,7 +1239,8 @@ void print_valid_ports(void)
                return -ENOENT;
        }
        ret = rte_flow_conv(RTE_FLOW_CONV_OP_ACTION_NAME_PTR,
-                           &name, sizeof(name), action, &error);
+                           &name, sizeof(name),
+                           (void *)(uintptr_t)action->type, &error);
        if (ret < 0)
                return port_flow_complain(&error);
        switch (action->type) {
-- 
1.8.3.1

Reply via email to