mirror of
https://git.yoctoproject.org/poky
synced 2026-04-21 21:32:12 +02:00
qemurunner: Log the second serial console as well as the first
To aid debugging, always log the second serial console as well as the first to a seperate log file. This should make it clearer what happened when we see test failures. (From OE-Core rev: 372cd58fe672726900af80f3e65a108984da2750) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
@@ -113,9 +113,9 @@ class QemuRunner:
|
||||
msg = re_control_char.sub('', msg)
|
||||
return msg
|
||||
|
||||
def log(self, msg):
|
||||
def log(self, msg, extension=""):
|
||||
if self.logfile:
|
||||
with codecs.open(self.logfile, "ab") as f:
|
||||
with codecs.open(self.logfile + extension, "ab") as f:
|
||||
f.write(msg)
|
||||
self.msg += self.decode_qemulog(msg)
|
||||
|
||||
@@ -477,10 +477,7 @@ class QemuRunner:
|
||||
data = data + read
|
||||
if data:
|
||||
bootlog += data
|
||||
if self.serial_ports < 2:
|
||||
# this file has mixed console/kernel data, log it to logfile
|
||||
self.log(data)
|
||||
|
||||
self.log(data, extension = ".2")
|
||||
data = b''
|
||||
|
||||
decodedlog = self.decode_qemulog(bootlog)
|
||||
|
||||
Reference in New Issue
Block a user