]> mj.ucw.cz Git - pciutils.git/commit
pcilmr: Ensure that utility can accept either Downstream or Upstream link port
authorNikita Proshkin <n.proshkin@yadro.com>
Wed, 22 May 2024 16:06:29 +0000 (19:06 +0300)
committerMartin Mares <mj@ucw.cz>
Mon, 27 May 2024 12:35:56 +0000 (14:35 +0200)
commit92399f441f34c31dbbbfd82461f155ab77cd5e74
tree1ad3353d2ca3b2cfec3cd2fd270bcba1174236b0
parent89cb2ae87236604b0e8ededd0fd7d9425c2d8cb6
pcilmr: Ensure that utility can accept either Downstream or Upstream link port

Previously, the utility expected only the Upstream Port to be input and,
in fact, passing the Downstream Port led to strange and buggy error
messages. Improve arguments parsing logic to accept any side of the link.

It seems that the only use case that will not be available now is margining
the internal links of the switch, but this scenario looks as strange as
possible.

Signed-off-by: Nikita Proshkin <n.proshkin@yadro.com>
lmr/lmr.h
lmr/margin.c
lmr/margin_hw.c
pcilmr.c