Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(391)

Unified Diff: server/site_linux_router.py

Issue 4006002: Add capability for using both radios in the AP at once (Closed) Base URL: ssh://gitrw.chromium.org/autotest.git
Patch Set: Remove tx_power -- defer to other CL Created 10 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: server/site_linux_router.py
diff --git a/server/site_linux_router.py b/server/site_linux_router.py
index 2405fe586adb058c5ab8ed0758e39cddd4d54d6e..ecc7f2e4612ffd82556b367bed819719fc26acd1 100644
--- a/server/site_linux_router.py
+++ b/server/site_linux_router.py
@@ -150,7 +150,10 @@ class LinuxRouter(object):
def config(self, params):
""" Configure the AP per test requirements """
- if self.hostapd['configured']:
+ multi_interface = 'multi_interface' in params
+ if multi_interface:
+ params.pop('multi_interface')
+ elif self.hostapd['configured']:
self.deconfig({})
if self.apmode:
@@ -284,14 +287,16 @@ class LinuxRouter(object):
# Set up the bridge.
logging.info("Setting up the bridge...")
- self.router.run("%s setfd %s %d" %
- (self.cmd_brctl, self.bridgeif, 0))
- self.router.run("%s addif %s %s" %
- (self.cmd_brctl, self.bridgeif, self.wiredif))
- self.router.run("%s link set %s up" %
- (self.cmd_ip, self.wiredif))
- self.router.run("%s link set %s up" %
- (self.cmd_ip, self.bridgeif))
+ if not multi_interface:
+ self.router.run("%s setfd %s %d" %
+ (self.cmd_brctl, self.bridgeif, 0))
+ self.router.run("%s addif %s %s" %
+ (self.cmd_brctl, self.bridgeif, self.wiredif))
+ self.router.run("%s link set %s up" %
+ (self.cmd_ip, self.wiredif))
+ self.router.run("%s link set %s up" %
+ (self.cmd_ip, self.bridgeif))
+ self.hostapd['interface'] = conf['interface']
logging.info("AP configured.")
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698