firmware

package
v0.0.0-...-683b059 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 23, 2022 License: BSD-3-Clause Imports: 52 Imported by: 0

Documentation

Overview

Package firmware contains remote Tast tests that exercise the firmware.

These tests typically perform operations that are risky or impossible to do in a local test such as suspending or rebooting the DUT.

Index

Constants

View Source
const (
	TrickleChargingThreshold = 100
)

Variables

This section is empty.

Functions

func APBmpblk

func APBmpblk(ctx context.Context, s *testing.State)

APBmpblk inspects coreboot contents for indicators of bitmap block configuration. See https://chromium.googlesource.com/chromiumos/platform/bmpblk for more context.

func BIOSCodeAB

func BIOSCodeAB(ctx context.Context, s *testing.State)

BIOSCodeAB reboots the EC, and looks for Port 80 code 0xab. On x86 platforms, depthcharge sends Port 80 code 0xab just before starting the kernel.

func BaseECUpdate

func BaseECUpdate(ctx context.Context, s *testing.State)

func BatteryCharging

func BatteryCharging(ctx context.Context, s *testing.State)

func BlockingSync

func BlockingSync(ctx context.Context, s *testing.State)

func BootBatteryCutoff

func BootBatteryCutoff(ctx context.Context, s *testing.State)

func BootMode

func BootMode(ctx context.Context, s *testing.State)

func BootTime

func BootTime(ctx context.Context, s *testing.State)

BootTime measures the time from EC boot to the first signal that the AP is booting. This test is not a hard rule, what really matters is the platform.BootPerfServerCrosPerf test. See go/chromeos-boottime for a proposal to revisit this. It appears that this test is not measuring the same thing as "Boot-to-Kernel" or "Boot to chromeball", but should catch a regression in that time.

func BootedDeviceReporter

func BootedDeviceReporter(ctx context.Context, s *testing.State)

func CheckKeyboardBacklightFunctionality

func CheckKeyboardBacklightFunctionality(ctx context.Context, s *testing.State)

CheckKeyboardBacklightFunctionality confirms keyboard backlight support and verifies its functionality.

func CheckServoKeyPresses

func CheckServoKeyPresses(ctx context.Context, s *testing.State)

func Config

func Config(ctx context.Context, s *testing.State)

func DUTBehaviourOnACInsertionInSleep

func DUTBehaviourOnACInsertionInSleep(ctx context.Context, s *testing.State)

func DUTWakeS3UsingPowerButton

func DUTWakeS3UsingPowerButton(ctx context.Context, s *testing.State)

func DeepSleep

func DeepSleep(ctx context.Context, s *testing.State)

DeepSleep has been tested to pass with Servo V4, Servo V4 + ServoMicro, Servo V4 + ServoMicro in dual V4 mode. Verified fail on SuzyQ because it charges the battery during the test.

func ECADC

func ECADC(ctx context.Context, s *testing.State)

ECADC mesaures the EC internal temperature sensors in a loop for couple of retries. This test might fail on boards which don't have "temps" EC command available.

func ECBattery

func ECBattery(ctx context.Context, s *testing.State)

func ECCbiEeprom

func ECCbiEeprom(ctx context.Context, s *testing.State)

func ECCharging

func ECCharging(ctx context.Context, s *testing.State)

ECCharging discharges the DUT then checks its voltages and current to determine its charging circuitry and EC reporting is working as intended

func ECChargingState

func ECChargingState(ctx context.Context, s *testing.State)

func ECConsole

func ECConsole(ctx context.Context, s *testing.State)

ECConsole opens the EC console and runs the version command.

func ECHash

func ECHash(ctx context.Context, s *testing.State)

ECHash tries to invalidate the hash of EC firmware and then check if it gets recomputed back again on warm reboot to ensure that AP correctly measures EC validity

func ECKeyboard

func ECKeyboard(ctx context.Context, s *testing.State)

func ECLaptopMode

func ECLaptopMode(ctx context.Context, s *testing.State)

func ECLidSwitch

func ECLidSwitch(ctx context.Context, s *testing.State)

func ECPowerButton

func ECPowerButton(ctx context.Context, s *testing.State)

func ECPowerG3

func ECPowerG3(ctx context.Context, s *testing.State)

func ECReboot

func ECReboot(ctx context.Context, s *testing.State)

func ECSharedMemory

func ECSharedMemory(ctx context.Context, s *testing.State)

func ECSize

func ECSize(ctx context.Context, s *testing.State)

func ECTabletMode

func ECTabletMode(ctx context.Context, s *testing.State)

func ECUSBPorts

func ECUSBPorts(ctx context.Context, s *testing.State)

func ECUpdateID

func ECUpdateID(ctx context.Context, s *testing.State)

func ECVerifyVK

func ECVerifyVK(ctx context.Context, s *testing.State)

func ECVersion

func ECVersion(ctx context.Context, s *testing.State)

func ECWakeOnCharge

func ECWakeOnCharge(ctx context.Context, s *testing.State)

func ECWakeSource

func ECWakeSource(ctx context.Context, s *testing.State)

func ECWatchdog

func ECWatchdog(ctx context.Context, s *testing.State)

func Eventlog

func Eventlog(ctx context.Context, s *testing.State)

func FWTries

func FWTries(ctx context.Context, s *testing.State)

func Fixture

func Fixture(ctx context.Context, s *testing.State)

func FlagsPreservation

func FlagsPreservation(ctx context.Context, s *testing.State)

func FpAddEntropy

func FpAddEntropy(ctx context.Context, s *testing.State)

func FpBioWash

func FpBioWash(ctx context.Context, s *testing.State)

func FpCheckWriteProtect

func FpCheckWriteProtect(ctx context.Context, s *testing.State)

FpCheckWriteProtect checks if changes in write protect signal are reflected in FPMCU. This is achieved by setting WP to some known state, checking if wpsw_cur value (from crossystem) reports WP state properly and check if WP state reported by FPMCU is also correct.

func FpFlashFpMcuHello

func FpFlashFpMcuHello(ctx context.Context, s *testing.State)

FpFlashFpMcuHello checks if the flash_fp_mcu script can properly communicate with the FPMCU's ROM/vendor bootloader (not EC RO). This is achieved by invoking flash_fp_mcu with the "--hello" option.

This does not have any preconditions, other than being able to disable the hardware write protect. This is because the *communication* with the bootloader should always be possible, regardless of the firmware/software-wp status of the FPMCU. However, flash_fp_mcu can fail if the FPMCU's FW doesn't respond after being returned to the normal operating mode. See https://source.chromium.org/search?q=file:flash_fp_mcu for behavior.

func FpRDP0

func FpRDP0(ctx context.Context, s *testing.State)

func FpRDP1

func FpRDP1(ctx context.Context, s *testing.State)

FpRDP1 test setup enables RDP level 1 by enabling hardware write protect and then enabling software write protect (with reboot of the EC); the test setup then disables hardware write protect, so that we can perform reads and change RDP levels through the bootloader (only accessible when HW write protect is disabled).

When the test script starts, a read through the bootloader is done without disabling flash protection (changing RDP state). We verify that we are unable to read any data.

Next a read through the bootloader is done, while also disabling flash protection (changing to RDP level 0), which triggers a mass erase. We verify that the bytes in the output are all 0xFF and that the firmware is no longer functional.

func FpROOnlyBootsValidRW

func FpROOnlyBootsValidRW(ctx context.Context, s *testing.State)

func FpRWNoUpdateRO

func FpRWNoUpdateRO(ctx context.Context, s *testing.State)

func FpReadFlash

func FpReadFlash(ctx context.Context, s *testing.State)

func FpRebootToRO

func FpRebootToRO(ctx context.Context, s *testing.State)

func FpSoftwareWriteProtect

func FpSoftwareWriteProtect(ctx context.Context, s *testing.State)

func FpSystemIsLocked

func FpSystemIsLocked(ctx context.Context, s *testing.State)

func FpTpmSeed

func FpTpmSeed(ctx context.Context, s *testing.State)

func FpUpdater

func FpUpdater(ctx context.Context, s *testing.State)

func FwFlashErasers

func FwFlashErasers(ctx context.Context, s *testing.State)

func FwmpDevDisableBoot

func FwmpDevDisableBoot(ctx context.Context, s *testing.State)

func GBBFlags

func GBBFlags(ctx context.Context, s *testing.State)

func H1Console

func H1Console(ctx context.Context, s *testing.State)

H1Console opens the H1 (cr50) console and runs the version command.

func H1Version

func H1Version(ctx context.Context, s *testing.State)

H1Version opens the H1 (cr50) console and verifies the version. Only runs from a chroot after running `sudo emerge chromeos-cr50`.

func HibernateFunctionality

func HibernateFunctionality(ctx context.Context, s *testing.State)

func PowerModes

func PowerModes(ctx context.Context, s *testing.State)

PowerModes verifies that system comes back after shutdown and coldreset.

func RemoteSerialPort

func RemoteSerialPort(ctx context.Context, s *testing.State)

func S3EntryExitAfterLidClose

func S3EntryExitAfterLidClose(ctx context.Context, s *testing.State)

func S3SuspendResume

func S3SuspendResume(ctx context.Context, s *testing.State)

func ScreenWakeTabletMode

func ScreenWakeTabletMode(ctx context.Context, s *testing.State)

func ServoGBBFlags

func ServoGBBFlags(ctx context.Context, s *testing.State)

ServoGBBFlags has been tested to pass with Suzy-Q, Servo V4, Servo V4 + ServoMicro in dual V4 mode. Verified fail on Servo V4 + ServoMicro w/o dual v4 mode. Has not been tested with with C2D2 (assumed to pass).

func ServoNetwork

func ServoNetwork(ctx context.Context, s *testing.State)

ServoNetwork attempts to verify that a machine in the lab can connect to servod without using ssh port forwarding. Delete this test after this is verified.

func ShutdownMode

func ShutdownMode(ctx context.Context, s *testing.State)

func SoftwareSync

func SoftwareSync(ctx context.Context, s *testing.State)

func Ti50CCDUpdate

func Ti50CCDUpdate(ctx context.Context, s *testing.State)

Ti50CCDUpdate requires HW setup with SuzyQ cable from Andreiboard to DUT.

func Ti50Demo

func Ti50Demo(ctx context.Context, s *testing.State)

func Ti50Rescue

func Ti50Rescue(ctx context.Context, s *testing.State)

func Ti50SystemTestImage

func Ti50SystemTestImage(ctx context.Context, s *testing.State)

func WriteProtect

func WriteProtect(ctx context.Context, s *testing.State)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL