Skip to content

Commit 2b797a5

Browse files
authored
Merge branch 'master' into RTSP-video-driver
2 parents 2475a5d + 64723a5 commit 2b797a5

5 files changed

Lines changed: 18 additions & 4 deletions

File tree

dockerfiles/staging/dut/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ RUN apt update -q=2 && \
1414

1515
COPY --chown=root:root ./authorized_keys /root/.ssh/authorized_keys
1616

17-
# As sshd scrubs ENV variables if they are set by the ENV varibale ensure to put the into /etc/profile as shown below
17+
# As sshd scrubs ENV variables if they are set by the ENV variable ensure to put the into /etc/profile as shown below
1818
ENV NOTVISIBLE="in users profile"
1919
RUN echo "export VISIBLE=now" >> /etc/profile
2020

examples/qemu-run.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ def main(args):
4141
"-s",
4242
"--state",
4343
default=os.environ.get("LG_STATE"),
44-
help="State to transition the strategy into (alternatively provided via LG_STATE",
44+
help="State to transition the strategy into (alternatively provided via LG_STATE)",
4545
)
4646
parser.add_argument(
4747
"-v",

labgrid/remote/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1862,7 +1862,7 @@ def get_parser(auto_doc_mode=False) -> "argparse.ArgumentParser | AutoProgramArg
18621862
"-s",
18631863
"--state",
18641864
type=str,
1865-
help="strategy state to switch into before command (default: value from env varibale LG_STATE)",
1865+
help="strategy state to switch into before command (default: value from env variable LG_STATE)",
18661866
)
18671867
parser.add_argument(
18681868
"-i",

labgrid/resource/udev.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,20 @@ def suggest_match(self, device):
107107
else:
108108
suggestions.append({'@ID_SERIAL_SHORT': serial})
109109

110+
# Multi-port USB serial adapters (e.g. WCH CH34x, FTDI multi) expose
111+
# several ports under one USB interface, so ID_PATH / ID_SERIAL_SHORT /
112+
# ID_USB_INTERFACE_NUM are identical for every port and the suggestions
113+
# above are ambiguous. The kernel's per-port `port_number` sysfs attr on
114+
# an ancestor is stable across re-enumeration; fold it into each
115+
# suggestion (as an `@` ancestor match) so every port is unique.
116+
for ancestor in self.device.ancestors:
117+
if ancestor.attributes.get('port_number') is not None:
118+
port_number = ancestor.attributes.asstring('port_number')
119+
for suggestion in suggestions:
120+
suggestion['@port_number'] = port_number
121+
meta['port_number'] = port_number
122+
break
123+
110124
return meta, suggestions
111125

112126
def try_match(self, device):

man/labgrid-client.1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ place name/alias (default: value from env variable LG_PLACE)
6363
.INDENT 0.0
6464
.TP
6565
.B \-s <state>, \-\-state <state>
66-
strategy state to switch into before command (default: value from env varibale LG_STATE)
66+
strategy state to switch into before command (default: value from env variable LG_STATE)
6767
.UNINDENT
6868
.INDENT 0.0
6969
.TP

0 commit comments

Comments
 (0)