diff options
Diffstat (limited to 'backport-qsf-Better-handling-of-Page-A2h-netlink-read-failure.patch')
-rw-r--r-- | backport-qsf-Better-handling-of-Page-A2h-netlink-read-failure.patch | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/backport-qsf-Better-handling-of-Page-A2h-netlink-read-failure.patch b/backport-qsf-Better-handling-of-Page-A2h-netlink-read-failure.patch new file mode 100644 index 0000000..ee3f2e1 --- /dev/null +++ b/backport-qsf-Better-handling-of-Page-A2h-netlink-read-failure.patch @@ -0,0 +1,32 @@ +From 814980faaef11c678524a0f93856a5ed6ff8f0d2 Mon Sep 17 00:00:00 2001 +From: Krzysztof Olędzki <ole@ans.pl> +Date: Wed, 11 Sep 2024 23:58:42 -0700 +Subject: qsf: Better handling of Page A2h netlink read failure + +Print "Failed to read Page A2h." error message to provide more context +for "netlink error: (...)" info. + +Signed-off-by: Krzysztof Piotr Oledzki <ole@ans.pl> +--- + sfpid.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/sfpid.c b/sfpid.c +index 1bc45c1..d9bda70 100644 +--- a/sfpid.c ++++ b/sfpid.c +@@ -494,8 +494,10 @@ int sff8079_show_all_nl(struct cmd_context *ctx) + /* Read A2h page */ + ret = sff8079_get_eeprom_page(ctx, SFF8079_I2C_ADDRESS_HIGH, + buf + ETH_MODULE_SFF_8079_LEN); +- if (ret) ++ if (ret) { ++ fprintf(stderr, "Failed to read Page A2h.\n"); + goto out; ++ } + + sff8472_show_all(buf); + out: +-- +cgit 1.2.3-korg + |