net/mlx5: fix devargs validation for multi-class probing
authorMichael Baum <michaelba@nvidia.com>
Thu, 25 Nov 2021 06:16:55 +0000 (08:16 +0200)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 26 Nov 2021 12:36:16 +0000 (13:36 +0100)
commit8648fa2f4688c2ef2d7991bcc3bfa20753862e8e
tree0e8c0f1851d1f18a9252200f87e821ccd1687236
parent63625c5da1853b6d5a4f44b713c7d4a3d49ceb0a
net/mlx5: fix devargs validation for multi-class probing

The mlx5_args function reads the devargs and checks if they are valid
for this driver and if not it returns an error.

This was normal behavior as long as all the devargs come to this driver,
but since it is possible to run several drivers together, the function
may return an error for another driver's devarg even though it is
completely valid.
In addition the function does not allow the user to know which of the
devargs is incorrect, but returns an error without printing the
unknown devarg.

This patch eliminates the error return in the case of an unknown devarg,
and prints a warning for each such devarg specifically.

Fixes: 7b4f1e6bd367 ("common/mlx5: introduce common library")
Cc: stable@dpdk.org
Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/mlx5.c