You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
20 lines
662 B
20 lines
662 B
7 months ago
|
# Copyright 2014 The Chromium OS Authors. All rights reserved.
|
||
|
# Use of this source code is governed by a BSD-style license that can be
|
||
|
# found in the LICENSE file.
|
||
|
|
||
|
from autotest_lib.client.common_lib import error
|
||
|
from autotest_lib.client.cros.cellular import mm
|
||
|
|
||
|
|
||
|
def ClearGobiModemFaultInjection():
|
||
|
"""If a Gobi modem is present, try to clear its fault-injection state."""
|
||
|
try:
|
||
|
modem_manager, modem_path = mm.PickOneModem('Gobi')
|
||
|
except error.TestError:
|
||
|
# Did not find a Gobi modem. Simply return.
|
||
|
return
|
||
|
|
||
|
modem = modem_manager.GetModem(modem_path).GobiModem()
|
||
|
if modem:
|
||
|
modem.InjectFault('ClearFaults', 1)
|