summaryrefslogtreecommitdiffstats
path: root/meta/lib/oeqa/utils/qemurunner.py
diff options
context:
space:
mode:
authorMikko Rapeli <mikko.rapeli@linaro.org>2022-11-18 18:08:27 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2022-11-22 12:26:46 +0000
commit8c5b1122554451290410df36e61ee3811c70e841 (patch)
tree869ba51e5deccee239351d4926114236338551df /meta/lib/oeqa/utils/qemurunner.py
parent44b0aa3426a41e55d12819ccb6b1494919b50ff7 (diff)
downloadpoky-8c5b1122554451290410df36e61ee3811c70e841.tar.gz
qemurunner.py: use IP address from command line
(From OE-Core rev: 44ab760c8ad7889b92019ec9341dfbec425ea4c0) Signed-off-by: Mikko Rapeli <mikko.rapeli@linaro.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib/oeqa/utils/qemurunner.py')
-rw-r--r--meta/lib/oeqa/utils/qemurunner.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/lib/oeqa/utils/qemurunner.py b/meta/lib/oeqa/utils/qemurunner.py
index df546c7bdd..b5fed6c9fe 100644
--- a/meta/lib/oeqa/utils/qemurunner.py
+++ b/meta/lib/oeqa/utils/qemurunner.py
@@ -406,9 +406,9 @@ class QemuRunner:
406 try: 406 try:
407 if self.use_slirp: 407 if self.use_slirp:
408 tcp_ports = cmdline.split("hostfwd=tcp:")[1] 408 tcp_ports = cmdline.split("hostfwd=tcp:")[1]
409 tcp_ports = tcp_ports.split(":")[1] 409 ip, tcp_ports = tcp_ports.split(":")[:2]
410 host_port = tcp_ports[:tcp_ports.find('-')] 410 host_port = tcp_ports[:tcp_ports.find('-')]
411 self.ip = "localhost:%s" % host_port 411 self.ip = "%s:%s" % (ip, host_port)
412 else: 412 else:
413 ips = re.findall(r"((?:[0-9]{1,3}\.){3}[0-9]{1,3})", cmdline.split("ip=")[1]) 413 ips = re.findall(r"((?:[0-9]{1,3}\.){3}[0-9]{1,3})", cmdline.split("ip=")[1])
414 self.ip = ips[0] 414 self.ip = ips[0]