mustang-uefi
UEFI
Arm 64-bit (AArch64)
Inheritance
- mustang-uefi
- base
Key facts
- Vendor
- Ampere / AppliedMicro
- Bootloader family
- UEFI
- Architecture
- Arm 64-bit (AArch64) (guessed from the name)
- Connections
- serial
Overridable variables (5)
Variables set with a default value in this template. They can be overridden from the device dictionary or, for some of them, from the job context.
| Variable | Default |
|---|---|
| boot_character_delay | 10 |
| console_device | 'ttyS0' |
| baud_rate | 115200 |
| tftp_mac | '00:01:73:69:5A:EF' |
| mustang_menu_list | menu_action_list |
Fixed settings (10)
| Variable | Value |
|---|---|
| base_menu_interrupt_prompt | menu_interrupt_prompt | default(base_menu_interrupt_prompt) |
| base_menu_interrupt_string | menu_interrupt_string | default(base_menu_interrupt_string) |
| base_item_markup_list | item_markup | default(base_item_markup_list) |
| base_item_class | item_class | default(base_item_class) |
| base_item_separator | item_separator | default(base_item_separator) |
| base_label_class | label_class | default(base_label_class) |
| base_menu_bootloader_prompt | bootloader_prompt | default(base_menu_bootloader_prompt) |
| base_menu_boot_message | boot_message | default(base_menu_boot_message) |
| base_early_printk | menu_early_printk | default('earlyprintk=uart8250-32bit,0x1c020000') |
| menu_action_list | [ {'item': 'Boot Manager'}, {'wait': 'Choice:'}, {'item': 'Remove Boot Device Entry', 'fallback': 'Return to Main Menu',}, {'wait': 'Delete entry'}, {'item': '{TEST_MENU_NAME}'}, {'wait': 'Choice:'}, {'item': 'Add Boot Device Entry'}, {'wait': "Select the Boot Device:"}, {'item': 'TFTP on MAC Address: ' ~ tftp_mac}, {'wait': "Get the IP address from DHCP:"}, {'enter': 'y'}, {'wait': "Get the TFTP server IP address:"}, {'enter': '{SERVER_IP}'}, {'wait': "File path of the EFI Application or the kernel :"}, {'enter': '{KERNEL}'}, {'wait': 'Is an EFI Application?'}, {'enter': 'n'}, {'wait': "Boot Type:"}, {'enter': 'f'}, {'wait': "Add an initrd:"}, {'enter': 'n'}, {'wait': "Get the IP address from DHCP:"}, {'enter': 'y'}, {'wait': "Get the TFTP server IP address:"}, {'enter': '{SERVER_IP}'}, {'wait': "File path of the FDT :"}, {'enter': '{DTB}'}, {'wait': 'Arguments to pass to the binary:'}, {'enter': "console=" ~ console_device ~ "," ~ baud_rate ~ " " ~ base_early_printk ~ " debug root=/dev/nfs rw " ~ base_nfsroot_args ~ " " ~ base_ip_args ~ ""}, {'wait': 'Description for this new Entry:'}, {'enter': '{TEST_MENU_NAME}'}, {'wait': "Choice:"}, {'item': 'Return to main menu'}, {'wait': "Start:"}, {'item': 'LAVA NFS Test Image'}, ] |
{# device_type: mustang-uefi #}
{% extends 'base.jinja2' %}
{% set boot_character_delay = boot_character_delay | default(10) %}
{% block body %}
{% set console_device = console_device | default('ttyS0') -%}
{% set baud_rate = baud_rate | default(115200) -%}
{% set tftp_mac = tftp_mac | default('00:01:73:69:5A:EF') -%}
{# allow job context override - use a different variable name, undefined if not in job context #}
{% set base_menu_interrupt_prompt = menu_interrupt_prompt | default(base_menu_interrupt_prompt) -%}
{% set base_menu_interrupt_string = menu_interrupt_string | default(base_menu_interrupt_string) -%}
{% set base_item_markup_list = item_markup | default(base_item_markup_list) -%}
{% set base_item_class = item_class | default(base_item_class) -%}
{% set base_item_separator = item_separator | default(base_item_separator) -%}
{% set base_label_class = label_class | default(base_label_class) -%}
{% set base_menu_bootloader_prompt = bootloader_prompt | default(base_menu_bootloader_prompt) -%}
{% set base_menu_boot_message = boot_message | default(base_menu_boot_message) -%}
{% set base_early_printk = menu_early_printk | default('earlyprintk=uart8250-32bit,0x1c020000') -%}
{# Consists of a list of dictionaries to enforce the order #}
{# tilde converts all operands to strings and concatenates in jinja2
see http://jinja.pocoo.org/docs/dev/templates/#other-operators
#}
{% set menu_action_list = [
{'item': 'Boot Manager'},
{'wait': 'Choice:'},
{'item': 'Remove Boot Device Entry', 'fallback': 'Return to Main Menu',},
{'wait': 'Delete entry'},
{'item': '{TEST_MENU_NAME}'},
{'wait': 'Choice:'},
{'item': 'Add Boot Device Entry'},
{'wait': "Select the Boot Device:"},
{'item': 'TFTP on MAC Address: ' ~ tftp_mac},
{'wait': "Get the IP address from DHCP:"},
{'enter': 'y'},
{'wait': "Get the TFTP server IP address:"},
{'enter': '{SERVER_IP}'},
{'wait': "File path of the EFI Application or the kernel :"},
{'enter': '{KERNEL}'},
{'wait': 'Is an EFI Application?'},
{'enter': 'n'},
{'wait': "Boot Type:"},
{'enter': 'f'},
{'wait': "Add an initrd:"},
{'enter': 'n'},
{'wait': "Get the IP address from DHCP:"},
{'enter': 'y'},
{'wait': "Get the TFTP server IP address:"},
{'enter': '{SERVER_IP}'},
{'wait': "File path of the FDT :"},
{'enter': '{DTB}'},
{'wait': 'Arguments to pass to the binary:'},
{'enter': "console=" ~ console_device ~ "," ~ baud_rate ~ " " ~ base_early_printk ~ " debug root=/dev/nfs rw " ~ base_nfsroot_args ~ " " ~ base_ip_args ~ ""},
{'wait': 'Description for this new Entry:'},
{'enter': '{TEST_MENU_NAME}'},
{'wait': "Choice:"},
{'item': 'Return to main menu'},
{'wait': "Start:"},
{'item': 'LAVA NFS Test Image'},
] -%}
{% set mustang_menu_list = mustang_menu_list | default(menu_action_list) -%}
actions:
deploy:
methods:
tftp:
ssh:
options:
{{ ssh_options }}
host: '{{ ssh_host|default('') }}'
user: {{ ssh_user|default('root') }}
port: {{ ssh_port|default(22) }}
identity_file: {{ ssh_identity_file }}
boot:
connections:
serial:
methods:
ssh:
uefi-menu:
parameters:
interrupt_prompt: {{ base_menu_interrupt_prompt }}
interrupt_string: '{{ base_menu_interrupt_string }}'
item_markup:
{{ base_item_markup_list }}
item_class: '{{ base_item_class }}'
separator: '{{ base_item_separator }}'
label_class: '{{ base_label_class }}'
bootloader_prompt: '{{ base_menu_bootloader_prompt }}'
boot_message: '{{ base_menu_boot_message }}'
nfs:
{% for test_dict in mustang_menu_list %}
{% for select, action in test_dict.items() %}
{% if select == 'item' %}
- select:
items:
{# This is ugly but the limitations of the template #}
{# prevent checking for a single match in a list against another list #}
{# FIXME: may need a jinja2 extension to make this support generic #}
{# http://jinja.pocoo.org/docs/dev/extensions/ #}
{% if 'tftp_mac' in action %}
- '{{ action|replace('tftp_mac', tftp_mac) }}'
{% elif 'console_device' in action %}
- '{{ action|replace('console_device', console_device) }}'
{% elif 'baud_rate' in action %}
- '{{ action|replace('baud_rate', baud_rate) }}'
{% else %}
- '{{ action }}'
{% endif %}
{% elif select == 'enter' %}
- select:
{% if 'tftp_mac' in action %}
enter: {{ action|replace('tftp_mac', tftp_mac) }}
{% elif 'console_device' in action %}
enter: {{ action|replace('console_device', console_device) }}
{% elif 'baud_rate' in action %}
enter: {{ action|replace('baud_rate', baud_rate) }}
{% else %}
enter: '{{ action }}'
{% endif %}
{% elif select == 'fallback' %}
fallback: '{{ action }}'
{% elif select == 'wait' %}
wait: '{{ action }}'
{% endif %}
{% endfor %}
{% endfor %}
{% endblock body %}
# in milliseconds
character_delays:
boot: 10
hostname: 'mustang-uefi-01'
devicetype: 'mustang-uefi'
constants:
# POSIX os (not AOSP)
posix:
lava_test_sh_cmd: /bin/sh
lava_test_results_dir: /lava-%s
lava_test_shell_file: ~/.bashrc
# bootloader specific
barebox:
interrupt-prompt: 'Hit m for menu or any other key to stop autoboot'
interrupt-character: '
'
final-message: 'Starting kernel'
error-messages:
- '### ERROR ### Please RESET the board ###'
- 'ERROR: .*'
- '.*: Out of memory'
u-boot:
interrupt-prompt: 'Hit any key to stop autoboot'
interrupt-character: ' '
interrupt_ctrl_list: []
interrupt-newline: True
final-message: 'Starting kernel'
error-messages:
- 'Resetting CPU'
- 'Must RESET board to recover'
- 'TIMEOUT'
- 'Retry count exceeded'
- 'Retry time exceeded; starting again'
- 'The remote end did not respond in time.'
- 'File not found'
- 'Bad Linux ARM64 Image magic!'
- 'Wrong Ramdisk Image Format'
- 'Ramdisk image is corrupt or invalid'
- 'ERROR: Failed to allocate'
- 'TFTP error: trying to overwrite reserved memory'
- 'Bad Linux RISCV Image magic!'
- 'Wrong Image Format for boot'
- 'ERROR: Did not find a cmdline Flattened Device Tree'
- 'ERROR: RD image overlaps OS image'
- 'kernel_comp_addr_r or kernel_comp_size is not provided'
- 'zimage: Bad magic'
dfu-download: 'DOWNLOAD \.\.\. OK\r\nCtrl\+C to exit \.\.\.'
grub:
interrupt-prompt: 'for a command-line'
interrupt-character: 'c'
interrupt-newline: False
error-messages:
- "error: missing (.*) symbol."
- "error: couldn't send network packet"
- "error: destination unreachable"
- "error: couldn't autoconfigure"
- "error: timeout reading"
- "error: you need to load the kernel first."
- "error: file '(.*)' not found"
- "error: no such device"
- "error: disk '(.*)' not found"
- "error: unknown filesystem"
grub-efi:
interrupt-prompt: 'for a command-line'
interrupt-character: 'c'
error-messages:
- 'Undefined OpCode Exception PC at'
- 'Synchronous Exception at'
- "error: missing (.*) symbol."
- "error: couldn't send network packet"
- "error: destination unreachable"
- "error: couldn't autoconfigure"
- "error: timeout reading"
- "error: you need to load the kernel first."
- "error: file '(.*)' not found"
- "error: no such device"
- "error: disk '(.*)' not found"
- "error: unknown filesystem"
ipxe:
interrupt-prompt: 'Press Ctrl-B for the iPXE command line'
interrupt_ctrl_list: ['b']
error-messages:
- 'No configuration methods succeeded'
- 'Connection timed out'
depthcharge:
final-message: 'Starting kernel'
error-messages:
- 'Tftp failed.'
- 'Dhcp release failed.'
- 'No space left for ramdisk'
- 'TFTP failed for ramdisk.'
- 'Dhcp release failed.'
- 'Out of space adding TFTP server IP to the command line.'
- 'No network device.'
- 'Error code \d+( \([\w\s]+\))?\r\n'
# OS shutdown message
# Override: set as the shutdown-message parameter of an Action.
# SHUTDOWN_MESSAGE
shutdown-message: 'The system is going down for reboot NOW'
# Kernel starting message
kernel-start-message: 'Linux version [0-9]'
# Default shell prompt for AutoLogin
# DEFAULT_SHELL_PROMPT
default-shell-prompt: 'lava-test: # '
# pexpect.spawn maxread
# SPAWN_MAXREAD - in bytes, quoted as a string
# 1 to turn off buffering, pexpect default is 2000
# maximum may be limited by platform issues to 4092
# avoid setting searchwindowsize:
# Data before searchwindowsize point is preserved, but not searched.
spawn_maxread: '4092'
# Set the failure retry to default or override it
failure_retry: 1
# Override boot_retry
boot_retry:
parameters:
# device_ip or device_mac
pass: # sata_uuid_sd_uuid_usb_uuid
actions:
deploy:
methods:
tftp:
ssh:
options:
- '-o'
- 'Compression=yes'
- '-o'
- 'PasswordAuthentication=no'
- '-o'
- 'LogLevel=FATAL'
host: ''
user: root
port: 22
identity_file: dynamic_vm_keys/lava
boot:
connections:
serial:
methods:
ssh:
uefi-menu:
parameters:
interrupt_prompt: The default boot selection will start in
interrupt_string: ' '
item_markup:
- "["
- "]"
item_class: '0-9'
separator: ' '
label_class: 'a-zA-Z0-9\s\:'
bootloader_prompt: 'Start:'
boot_message: 'Loaded: LinuxImage'
nfs:
- select:
items:
- 'Boot Manager'
wait: 'Choice:'
- select:
items:
- 'Remove Boot Device Entry'
fallback: 'Return to Main Menu'
wait: 'Delete entry'
- select:
items:
- '{TEST_MENU_NAME}'
wait: 'Choice:'
- select:
items:
- 'Add Boot Device Entry'
wait: 'Select the Boot Device:'
- select:
items:
- 'TFTP on MAC Address: 00:01:73:69:5A:EF'
wait: 'Get the IP address from DHCP:'
- select:
enter: 'y'
wait: 'Get the TFTP server IP address:'
- select:
enter: '{SERVER_IP}'
wait: 'File path of the EFI Application or the kernel :'
- select:
enter: '{KERNEL}'
wait: 'Is an EFI Application?'
- select:
enter: 'n'
wait: 'Boot Type:'
- select:
enter: 'f'
wait: 'Add an initrd:'
- select:
enter: 'n'
wait: 'Get the IP address from DHCP:'
- select:
enter: 'y'
wait: 'Get the TFTP server IP address:'
- select:
enter: '{SERVER_IP}'
wait: 'File path of the FDT :'
- select:
enter: '{DTB}'
wait: 'Arguments to pass to the binary:'
- select:
enter: 'console=ttyS0,115200 earlyprintk=uart8250-32bit,0x1c020000 debug root=/dev/nfs rw nfsroot={NFS_SERVER_IP}:{NFSROOTFS},tcp,hard ip=dhcp'
wait: 'Description for this new Entry:'
- select:
enter: '{TEST_MENU_NAME}'
wait: 'Choice:'
- select:
items:
- 'Return to main menu'
wait: 'Start:'
- select:
items:
- 'LAVA NFS Test Image'
timeouts:
actions:
apply-overlay-image:
minutes: 2
dd-image:
minutes: 10
download-retry:
minutes: 15
http-download:
minutes: 5
lava-test-shell:
minutes: 3
nfs-deploy:
minutes: 10
power-off:
seconds: 10
bootloader-commands:
minutes: 3
bootloader-interrupt:
seconds: 30
u-boot-interrupt:
seconds: 30
umount-retry:
seconds: 45
auto-login-action:
minutes: 2
bootloader-action:
minutes: 3
uboot-action:
minutes: 3
uboot-commands:
minutes: 3
bootloader-retry:
minutes: 3
boot-qemu-image:
minutes: 2
boot-image-retry:
minutes: 2
flash-uboot-ums:
minutes: 20
musca-deploy:
minutes: 3
musca-boot:
minutes: 1
unmount-musca-usbmsd:
seconds: 30
pdu-reboot:
seconds: 30
reset-device:
seconds: 30
connections:
dd-image:
minutes: 10
uboot-commands:
seconds: 30
bootloader-commands:
seconds: 30
auto-login-action:
minutes: 2
bootloader-interrupt:
seconds: 30
u-boot-interrupt:
seconds: 30
lava-test-shell:
seconds: 10
lava-docker-test-shell:
seconds: 10
Rendered with the default values (no device dictionary), using LAVA's own template environment.