diff mbox series

[v2] tests: hwsim: suppress annoying console reset from VMs

Message ID 20190203205423.7534-1-johannes@sipsolutions.net
State Superseded
Headers show
Series [v2] tests: hwsim: suppress annoying console reset from VMs | expand

Commit Message

Johannes Berg Feb. 3, 2019, 8:54 p.m. UTC
From: Johannes Berg <johannes.berg@intel.com>

Recently, qemu/seabios grew an annoying console/terminal reset,
which also causes my terminal to be left in a state where long
lines don't work well and less gets confused because of this.

Suppress this by suppressing all output from qemu before the
'magic' words "running inside a VM" from run-all.sh.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
---
 tests/hwsim/vm/vm-run.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Johannes Berg Feb. 5, 2019, 10:54 a.m. UTC | #1
On Sun, 2019-02-03 at 21:54 +0100, Johannes Berg wrote:
> From: Johannes Berg <johannes.berg@intel.com>
> 
> Recently, qemu/seabios grew an annoying console/terminal reset,
> which also causes my terminal to be left in a state where long
> lines don't work well and less gets confused because of this.
> 
> Suppress this by suppressing all output from qemu before the
> 'magic' words "running inside a VM" from run-all.sh.

Hmm. It occurred to me that these were *only* ever printed when running
in a VM, and there's likely to have been a reason for that, and so I
shouldn't just suppress them.

What do you think? I can instead add another print, e.g. at the
beginning of 'inside.sh', that we key off in the sed.

johannes
diff mbox series

Patch

diff --git a/tests/hwsim/vm/vm-run.sh b/tests/hwsim/vm/vm-run.sh
index 1712ed349647..67168da9b08c 100755
--- a/tests/hwsim/vm/vm-run.sh
+++ b/tests/hwsim/vm/vm-run.sh
@@ -134,7 +134,8 @@  $KVM \
 	-fsdev local,security_model=none,id=fsdev-logs,path="$LOGDIR",writeout=immediate \
 	-device virtio-9p-pci,id=fs-logs,fsdev=fsdev-logs,mount_tag=logshare \
 	-monitor null -serial stdio -serial file:$LOGDIR/console \
-	-append "mac80211_hwsim.support_p2p_device=0 mac80211_hwsim.channels=$CHANNELS mac80211_hwsim.radios=7 cfg80211.dyndbg=+p mac80211.dyndbg=+p mac80211_hwsim.dyndbg=+p init=$CMD testdir=$TESTDIR timewarp=$TIMEWARP console=$KVMOUT root=/dev/root rootflags=trans=virtio,version=9p2000.u ro rootfstype=9p EPATH=$EPATH ARGS=$argsfile"
+	-append "mac80211_hwsim.support_p2p_device=0 mac80211_hwsim.channels=$CHANNELS mac80211_hwsim.radios=7 cfg80211.dyndbg=+p mac80211.dyndbg=+p mac80211_hwsim.dyndbg=+p init=$CMD testdir=$TESTDIR timewarp=$TIMEWARP console=$KVMOUT root=/dev/root rootflags=trans=virtio,version=9p2000.u ro rootfstype=9p EPATH=$EPATH ARGS=$argsfile" | \
+	sed -u '1,/running inside a VM/d'
 
 if [ $CODECOV = "yes" ]; then
     echo "Preparing code coverage reports"