[PATCH v4] bus: fix device iterator match from arguments

Xueming(Steven) Li xuemingl at nvidia.com
Wed Nov 24 14:00:06 CET 2021


On Wed, 2021-11-24 at 13:45 +0100, Olivier Matz wrote:
> From: Xueming Li <xuemingl at nvidia.com>
> 
> Device iterator RTE_DEV_FOREACH() failed to return devices from
> classifier like "class=vdpa", because matching name from empty kvargs
> returns no result. If device name not specified in kvargs, the function
> should iterate all devices.
> 
> This patch allows empty devargs or devargs without name specified.
> 
> Fixes: 6aebb942907d ("kvargs: add function to get from key and value")
> 
> Signed-off-by: Xueming Li <xuemingl at nvidia.com>
> Signed-off-by: Olivier Matz <olivier.matz at 6wind.com>
> Reviewed-by: Xueming Li <xuemingl at nvidia.com>
> ---
> bug is specific to 21.11, no need to cc stable at dpdk.org
> 
> v4:
> - disable unit test when net/null is not enabled
> v3:
> - add unit test
> v2:
> - use rte_kvargs_get() + strcmp instead of rte_kvargs_get_with_value()

Acked-by: Xueming Li <xuemingl at nvidia.com>


More information about the dev mailing list