• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright 2019 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
5from autotest_lib.server import utils
6
7AUTHOR = "mruthven"
8NAME = "firmware_Cr50TpmManufactured"
9PURPOSE = "Check if the TPM is manufactured."
10ATTRIBUTES = "suite:faft_cr50_prepvt, suite:faft_cr50_pvt"
11TIME = "SHORT"
12TEST_TYPE = "server"
13DEPENDENCIES = "servo_state:WORKING"
14
15DOC = """Check if the TPM is manufactured.
16
17Cr50 will manufacture the TPM if the manufacturing space is ok. If we reset the
18TPM and it isn't manufactured, then it's likely the manufacturing space is
19corrupted. Corrupted manufacturing space can cause all sorts of weird issues.
20This test can be used to find bad boards and possibly find issues with Cr50
21images. Most of the time this issue is caused by bad DBG images, so it can
22highlight those issues, but the test is mainly to make sure there aren't broken
23boards in the lab.
24"""
25
26if 'args_dict' not in locals():
27    args_dict = {}
28
29args_dict.update(utils.args_to_dict(args))
30servo_args = hosts.CrosHost.get_servo_arguments(args_dict)
31
32def run(machine):
33    host = hosts.create_host(machine, servo_args=servo_args)
34
35    iterations = int(args_dict.get("iterations", 1))
36
37    job.run_test("firmware_Cr50TpmManufactured", host=host, cmdline_args=args,
38                 full_args=args_dict, iterations=iterations)
39
40parallel_simple(run, machines)
41