svn commit: r347853 - stable/11/sys/dev/mlx5/mlx5_core
Hans Petter Selasky
hselasky at FreeBSD.org
Thu May 16 18:05:17 UTC 2019
Author: hselasky
Date: Thu May 16 18:05:16 2019
New Revision: 347853
URL: https://svnweb.freebsd.org/changeset/base/347853
Log:
MFC r347297:
Control automatic update of firmware on driver load with a tunable in mlx5core.
Submitted by: kib@
Sponsored by: Mellanox Technologies
Modified:
stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c
Directory Properties:
stable/11/ (props changed)
Modified: stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c
==============================================================================
--- stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Thu May 16 18:03:08 2019 (r347852)
+++ stable/11/sys/dev/mlx5/mlx5_core/mlx5_main.c Thu May 16 18:05:16 2019 (r347853)
@@ -821,12 +821,19 @@ void *mlx5_get_protocol_dev(struct mlx5_core_dev *mdev
}
EXPORT_SYMBOL(mlx5_get_protocol_dev);
+static int mlx5_auto_fw_update;
+SYSCTL_INT(_hw_mlx5, OID_AUTO, auto_fw_update, CTLFLAG_RDTUN | CTLFLAG_NOFETCH,
+ &mlx5_auto_fw_update, 0,
+ "Allow automatic firmware update on driver start");
static int
mlx5_firmware_update(struct mlx5_core_dev *dev)
{
const struct firmware *fw;
int err;
+ TUNABLE_INT_FETCH("hw.mlx5.auto_fw_update", &mlx5_auto_fw_update);
+ if (!mlx5_auto_fw_update)
+ return (0);
fw = firmware_get("mlx5fw_mfa");
if (fw) {
err = mlx5_firmware_flash(dev, fw);
More information about the svn-src-stable-11
mailing list