diff mbox series

tests: Fix sporadic failures in p2p_channel_avoid3

Message ID 20210121154037.32654-5-andrei.otcheretianski@intel.com
State Accepted
Headers show
Series tests: Fix sporadic failures in p2p_channel_avoid3 | expand

Commit Message

Andrei Otcheretianski Jan. 21, 2021, 3:40 p.m. UTC
The p2p group may be originally formated on UNII-3, so disabling UNII-1
and UNII-2 will not result in a channel switch failing the test.
Fix this by setting 44 as a preferred channel.

Signed-off-by: Andrei Otcheretianski <andrei.otcheretianski@intel.com>
---
 tests/hwsim/test_p2p_channel.py | 2 ++
 1 file changed, 2 insertions(+)

Comments

Jouni Malinen Feb. 6, 2021, 10:15 a.m. UTC | #1
On Thu, Jan 21, 2021 at 05:40:36PM +0200, Andrei Otcheretianski wrote:
> The p2p group may be originally formated on UNII-3, so disabling UNII-1
> and UNII-2 will not result in a channel switch failing the test.
> Fix this by setting 44 as a preferred channel.

Thanks, applied.
diff mbox series

Patch

diff --git a/tests/hwsim/test_p2p_channel.py b/tests/hwsim/test_p2p_channel.py
index 7bbc958b9f..8923ca17c2 100644
--- a/tests/hwsim/test_p2p_channel.py
+++ b/tests/hwsim/test_p2p_channel.py
@@ -226,6 +226,7 @@  def test_p2p_channel_avoid2(dev):
 def test_p2p_channel_avoid3(dev):
     """P2P and avoid frequencies driver event on 5 GHz"""
     try:
+        dev[0].global_request("SET p2p_pref_chan 128:44")
         set_country("CN", dev[0])
         form(dev[0], dev[1])
         set_country("CN", dev[0])
@@ -251,6 +252,7 @@  def test_p2p_channel_avoid3(dev):
     finally:
         set_country("00")
         dev[0].request("DRIVER_EVENT AVOID_FREQUENCIES")
+        dev[0].global_request("SET p2p_pref_chan ")
         dev[1].flush_scan_cache()
 
 @remote_compatible