net/mlx5: fix duplicate pattern option default
authorMichael Baum <michaelba@nvidia.com>
Sun, 12 Sep 2021 10:36:25 +0000 (13:36 +0300)
committerThomas Monjalon <thomas@monjalon.net>
Mon, 20 Sep 2021 21:13:40 +0000 (23:13 +0200)
commit97c9b0aa25d7b32cb4723389c31462a8f3be3f41
tree44224423f962a215ff85422b32bcd1764bce6512
parent6856efa54eea23ce2079a23cb661e009421fb833
net/mlx5: fix duplicate pattern option default

In order to allow/disallow configuring rules with identical patterns,
the new device argument 'allow_duplicate_pattern' was introduced.

The default is to allow, and it is initialized to 1 in PCI probe
function.
However, on auxiliary bus probing (for Sub-Function) it is not
initialized at all, so it's actually initialized to 0.

Move the initialization to default config function which is called from
both.

Fixes: 919488fbfa71 ("net/mlx5: support Sub-Function")
Cc: stable@dpdk.org
Signed-off-by: Michael Baum <michaelba@nvidia.com>
Acked-by: Matan Azrad <matan@nvidia.com>
drivers/net/mlx5/linux/mlx5_os.c