git: 5b1211bb358f - stable/14 - mlx5en: limit reporting eeprom read failure due to unplugged module to verboseboot

From: Konstantin Belousov <kib_at_FreeBSD.org>
Date: Tue, 06 Aug 2024 02:46:47 UTC
The branch stable/14 has been updated by kib:

URL: https://cgit.FreeBSD.org/src/commit/?id=5b1211bb358f649b36375361395359541b3ed5d7

commit 5b1211bb358f649b36375361395359541b3ed5d7
Author:     Konstantin Belousov <kib@FreeBSD.org>
AuthorDate: 2024-07-26 21:09:58 +0000
Commit:     Konstantin Belousov <kib@FreeBSD.org>
CommitDate: 2024-08-06 02:46:26 +0000

    mlx5en: limit reporting eeprom read failure due to unplugged module to verboseboot
    
    (cherry picked from commit 2204a4829083bf2a40304ea873d287a5498973d7)
---
 sys/dev/mlx5/mlx5_en/mlx5_en_main.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/sys/dev/mlx5/mlx5_en/mlx5_en_main.c b/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
index 97ec1b4420a8..55a4bc3cec79 100644
--- a/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
+++ b/sys/dev/mlx5/mlx5_en/mlx5_en_main.c
@@ -3674,9 +3674,11 @@ out:
 		/* Check if module is present before doing an access */
 		module_status = mlx5_query_module_status(priv->mdev, module_num);
 		if (module_status != MLX5_MODULE_STATUS_PLUGGED_ENABLED) {
-			mlx5_en_err(ifp,
-			    "Query module %d status: not plugged (%d), eeprom reading is not supported\n",
-			    module_num, module_status);
+			if (bootverbose)
+				mlx5_en_err(ifp,
+				    "Query module %d status: not plugged (%d), "
+				    "eeprom reading is not supported\n",
+				    module_num, module_status);
 			error = EINVAL;
 			goto err_i2c;
 		}