• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2015 The Chromium OS Authors. All rights reserved.
2# Use of this source code is governed by a BSD-style license that can be
3# found in the LICENSE file.
4
5
6AUTHOR = "chromeos-lab-infrastructure"
7NAME = "provision_FirmwareUpdate.rw_only"
8PURPOSE = "Provision a system to the correct firmware version, update RW only."
9TIME = "MEDIUM"
10TEST_CATEGORY = "System"
11TEST_CLASS = "provision"
12TEST_TYPE = "Server"
13
14DOC = """
15This is a test used by the provision control segment in autoserv to set the
16fwrw-version label of a host to the desired setting. This test attempts to
17reprogram only RW of both EC and AP firmware.
18"""
19
20
21from autotest_lib.client.common_lib import error, utils
22
23
24args_dict = utils.args_to_dict(args)
25servo_args = hosts.CrosHost.get_servo_arguments(args_dict)
26
27
28if not locals().get('value'):
29    if not args_dict.get('value'):
30        raise error.TestError("No provision value!")
31    value = args_dict['value']
32
33
34if not locals().get('fw_path'):
35    fw_path = args_dict.get('fw_path', None)
36
37
38def run(machine):
39    host = hosts.create_host(machine, servo_args=servo_args)
40    job.run_test('provision_FirmwareUpdate', host=host, value=value,
41                 rw_only=True, disable_sysinfo=True, fw_path=fw_path)
42
43
44job.parallel_simple(run, machines)
45