mlx5en: Make the hw_lro parameter read only tunable.

This prevents the so-called TIR context from changing during runtime.

MFC after:	1 week
Sponsored by:	NVIDIA Networking
This commit is contained in:
Hans Petter Selasky 2022-02-01 16:20:05 +01:00
parent 788e9e7478
commit a60f953424

View File

@ -1473,6 +1473,12 @@ mlx5e_create_ethtool(struct mlx5e_priv *priv)
mlx5e_params_desc[2 * x], CTLTYPE_U64 | CTLFLAG_RD |
CTLFLAG_MPSAFE, priv, x, &mlx5e_ethtool_handler, "QU",
mlx5e_params_desc[2 * x + 1]);
} else if (strcmp(mlx5e_params_desc[2 * x], "hw_lro") == 0) {
/* read-only, but tunable parameters */
SYSCTL_ADD_PROC(&priv->sysctl_ctx, SYSCTL_CHILDREN(node), OID_AUTO,
mlx5e_params_desc[2 * x], CTLTYPE_U64 | CTLFLAG_RDTUN |
CTLFLAG_MPSAFE, priv, x, &mlx5e_ethtool_handler, "QU",
mlx5e_params_desc[2 * x + 1]);
} else {
/*
* NOTE: In FreeBSD-11 and newer the