summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKonrad Weihmann <kweihmann@outlook.com>2020-05-27 20:07:58 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2020-05-30 12:32:47 +0100
commitc77870372231e30b555e5f35aeb5db373020655e (patch)
treeb9be744223d23f2e1285d4961b3b1a2cebe273ca
parent97377e284d5e7f9b5efeca643c23bf1c10d5114c (diff)
downloadpoky-c77870372231e30b555e5f35aeb5db373020655e.tar.gz
qemurunner: fix ip fallback detection
When falling back from detecting ip from /proc/./cmdline the output of runqemu is acutally 'Network configuration: ip=192.168.7.2::192.168.7.1::255.255.255.0' which doesn't match the given regex and leading to run failure, although IP is detectable. Fix regex by inserting an optional 'ip=' prefix to first IP (From OE-Core rev: 75f2471d15fab024775c59cb70c54e3f25f9ae72) Signed-off-by: Konrad Weihmann <kweihmann@outlook.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/utils/qemurunner.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/lib/oeqa/utils/qemurunner.py b/meta/lib/oeqa/utils/qemurunner.py
index 4b74337652..992fff9370 100644
--- a/meta/lib/oeqa/utils/qemurunner.py
+++ b/meta/lib/oeqa/utils/qemurunner.py
@@ -290,7 +290,7 @@ class QemuRunner:
290 self.logger.debug("qemu cmdline used:\n{}".format(cmdline)) 290 self.logger.debug("qemu cmdline used:\n{}".format(cmdline))
291 except (IndexError, ValueError): 291 except (IndexError, ValueError):
292 # Try to get network configuration from runqemu output 292 # Try to get network configuration from runqemu output
293 match = re.match(r'.*Network configuration: ([0-9.]+)::([0-9.]+):([0-9.]+)$.*', 293 match = re.match(r'.*Network configuration: (?:ip=)*([0-9.]+)::([0-9.]+):([0-9.]+)$.*',
294 out, re.MULTILINE|re.DOTALL) 294 out, re.MULTILINE|re.DOTALL)
295 if match: 295 if match:
296 self.ip, self.server_ip, self.netmask = match.groups() 296 self.ip, self.server_ip, self.netmask = match.groups()