From 5f7ca76cb46b86a6f9adcbebe995a54972fa5abf Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sun, 22 Mar 2020 15:39:40 +0100 Subject: wireless: T1627: add validator on physical-interface A physical (phy) interface is mandatory for WiFi to work. --- src/conf_mode/interfaces-wireless.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/conf_mode/interfaces-wireless.py') diff --git a/src/conf_mode/interfaces-wireless.py b/src/conf_mode/interfaces-wireless.py index 40ee2b418..6528e57f1 100755 --- a/src/conf_mode/interfaces-wireless.py +++ b/src/conf_mode/interfaces-wireless.py @@ -1288,6 +1288,9 @@ def verify(wifi): if wifi['type'] != 'monitor' and not wifi['ssid']: raise ConfigError('SSID must be set for {}'.format(wifi['intf'])) + if not wifi['phy']: + raise ConfigError('You must specify physical-device') + if wifi['type'] == 'access-point': c = Config() if not c.exists('system wifi-regulatory-domain'): -- cgit v1.2.3