From 4ecf11c55925edf79f6a061508e8ede39d1cc07d Mon Sep 17 00:00:00 2001 From: Johannes Berg Date: Wed, 6 Nov 2013 14:11:17 +0100 Subject: [PATCH] hwsim tests: Make channel configuration for VM tests easier Add a CHANNELS configuration to the script running the VM that can be added to the vm-config file to allow running the tests with hwsim devices supporting more than a single channel. Eventually, with the (hopefully) upcoming dynamic work in mac80211_hwsim, this might go away entirely, but for now this allows testing more code paths. Signed-hostap: Johannes Berg --- tests/hwsim/vm/vm-run.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/hwsim/vm/vm-run.sh b/tests/hwsim/vm/vm-run.sh index b63a76c08..dd245d4ff 100755 --- a/tests/hwsim/vm/vm-run.sh +++ b/tests/hwsim/vm/vm-run.sh @@ -25,6 +25,9 @@ KVMOUT=ttyS1 # extra KVM arguments, e.g., -s for gdbserver #KVMARGS=-s +# number of channels each hwsim device supports +CHANNELS=1 + test -f vm-config && . vm-config if [ -z "$KERNEL" ] && [ -z "$KERNELDIR" ] ; then @@ -48,4 +51,4 @@ exec 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.radios=5 init=$CMD testdir=$TESTDIR console=$KVMOUT root=/dev/root rootflags=trans=virtio,version=9p2000.u ro rootfstype=9p EPATH=$EPATH ARGS=$*" + -append "mac80211_hwsim.channels=$CHANNELS mac80211_hwsim.radios=5 init=$CMD testdir=$TESTDIR console=$KVMOUT root=/dev/root rootflags=trans=virtio,version=9p2000.u ro rootfstype=9p EPATH=$EPATH ARGS=$*"