Commit 2d4b75b1 authored by Adam Wujek's avatar Adam Wujek 💬

userspace/tools: use 1..18 port numbering in wrs_sfp_dump

Signed-off-by: Adam Wujek's avatarAdam Wujek <adam.wujek@cern.ch>
parent 2b6c0bc2
......@@ -79,14 +79,14 @@ int main(int argc, char **argv)
for (i = dump_port; i <= nports; i++) {
memset(&shdr, 0, sizeof(shdr));
printf("========= port %d =========\n", i - 1);
printf("========= port %d =========\n", i);
err = shw_sfp_read_verify_header(i - 1, &shdr);
if (err == -2) {
pr_error("SFP module not inserted in port %d. Failed "
"to read SFP configuration header\n", i - 1);
"to read SFP configuration header\n", i);
} else if (err < 0) {
pr_error("Failed to read SFP configuration header on "
"port %d\n", i - 1);
"port %d\n", i);
} else {
shw_sfp_print_header(&shdr);
if (dump_hex_header) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment