Software APIs
chip.h File Reference

Chip-level constants. More...

Go to the source code of this file.

Macros

#define CHIP_MANIFEST_SIZE   1024
 Manifest size for boot stages stored in flash (in bytes).
 
#define CHIP_MANIFEST_VERSION_MINOR_1   0x6c47
 Manifest format major and minor versions.
 
#define CHIP_MANIFEST_VERSION_MAJOR_1   0x71c3
 
#define CHIP_MANIFEST_VERSION_MAJOR_2   0x0002
 
#define CHIP_MANIFEST_EXT_TABLE_ENTRY_COUNT   15
 Number of entries in the manifest extensions table.
 
#define CHIP_BOOT_SVC_MSG_HEADER_SIZE   44
 Size of the header of a boot services message.
 
#define CHIP_BOOT_SVC_MSG_SIZE_MAX   256
 Maximum size of a boot services message.
 
#define CHIP_BOOT_SVC_MSG_PAYLOAD_SIZE_MAX    (CHIP_BOOT_SVC_MSG_SIZE_MAX - CHIP_BOOT_SVC_MSG_HEADER_SIZE)
 Maximum payload size for a boot services message.
 
#define CHIP_BL0_IDENTIFIER   0x3042544f
 First owner boot stage, e.g.
 
#define CHIP_BL0_SIZE_MIN   CHIP_MANIFEST_SIZE
 Allowed bounds for the length field of a first owner boot stage manifest.
 
#define CHIP_BL0_SIZE_MAX   0x70000
 
#define CHIP_ROM_EXT_IDENTIFIER   0x4552544f
 ROM_EXT manifest identifier (ASCII "OTRE").
 
#define CHIP_ROM_EXT_SIZE_MIN   CHIP_MANIFEST_SIZE
 Allowed bounds for the length field of a ROM_EXT manifest.
 
#define CHIP_ROM_EXT_SIZE_MAX   0x10000
 
#define CHIP_ROM_EXT_RESIZABLE_SIZE_MAX    (CHIP_ROM_EXT_SIZE_MAX + CHIP_BL0_SIZE_MAX)
 
#define TEST_ROM_IDENTIFIER   0x54534554
 Value written to the end of the retention SRAM creator area by test_rom to be able to determine the type of ROM in tests (ASCII "TEST").
 
#define PINMUX_PAD_ATTR_PROP_CYCLES   500
 Pinmux pull up/down wait delay.
 
#define SW_STRAP_0_PERIPH   22
 Pinmux peripheral input values for software strap pins.
 
#define SW_STRAP_1_PERIPH   23
 
#define SW_STRAP_2_PERIPH   24
 
#define SW_STRAP_0_INSEL   24
 Pinmux MIO input selector values for software strap pins.
 
#define SW_STRAP_1_INSEL   25
 
#define SW_STRAP_2_INSEL   26
 
#define SW_STRAP_0_PAD   22
 Pads of the software strap pins.
 
#define SW_STRAP_1_PAD   23
 
#define SW_STRAP_2_PAD   24
 
#define SW_STRAP_MASK
 Mask for the software strap pins.
 
#define SW_STRAP_RMA_ENTRY
 RMA entry strap value.
 
#define SW_STRAP_BOOTSTRAP
 Bootstrap strap value.
 

Detailed Description

Chip-level constants.

Definition in file chip.h.

Macro Definition Documentation

◆ CHIP_BL0_IDENTIFIER

#define CHIP_BL0_IDENTIFIER   0x3042544f

First owner boot stage, e.g.

BL0, manifest identifier (ASCII "OTB0").

Definition at line 52 of file chip.h.

◆ CHIP_BL0_SIZE_MAX

#define CHIP_BL0_SIZE_MAX   0x70000

Definition at line 58 of file chip.h.

◆ CHIP_BL0_SIZE_MIN

#define CHIP_BL0_SIZE_MIN   CHIP_MANIFEST_SIZE

Allowed bounds for the length field of a first owner boot stage manifest.

Definition at line 57 of file chip.h.

◆ CHIP_BOOT_SVC_MSG_HEADER_SIZE

#define CHIP_BOOT_SVC_MSG_HEADER_SIZE   44

Size of the header of a boot services message.

Definition at line 36 of file chip.h.

◆ CHIP_BOOT_SVC_MSG_PAYLOAD_SIZE_MAX

#define CHIP_BOOT_SVC_MSG_PAYLOAD_SIZE_MAX    (CHIP_BOOT_SVC_MSG_SIZE_MAX - CHIP_BOOT_SVC_MSG_HEADER_SIZE)

Maximum payload size for a boot services message.

Definition at line 46 of file chip.h.

◆ CHIP_BOOT_SVC_MSG_SIZE_MAX

#define CHIP_BOOT_SVC_MSG_SIZE_MAX   256

Maximum size of a boot services message.

Definition at line 41 of file chip.h.

◆ CHIP_MANIFEST_EXT_TABLE_ENTRY_COUNT

#define CHIP_MANIFEST_EXT_TABLE_ENTRY_COUNT   15

Number of entries in the manifest extensions table.

Definition at line 31 of file chip.h.

◆ CHIP_MANIFEST_SIZE

#define CHIP_MANIFEST_SIZE   1024

Manifest size for boot stages stored in flash (in bytes).

Definition at line 16 of file chip.h.

◆ CHIP_MANIFEST_VERSION_MAJOR_1

#define CHIP_MANIFEST_VERSION_MAJOR_1   0x71c3

Definition at line 22 of file chip.h.

◆ CHIP_MANIFEST_VERSION_MAJOR_2

#define CHIP_MANIFEST_VERSION_MAJOR_2   0x0002

Definition at line 26 of file chip.h.

◆ CHIP_MANIFEST_VERSION_MINOR_1

#define CHIP_MANIFEST_VERSION_MINOR_1   0x6c47

Manifest format major and minor versions.

Definition at line 21 of file chip.h.

◆ CHIP_ROM_EXT_IDENTIFIER

#define CHIP_ROM_EXT_IDENTIFIER   0x4552544f

ROM_EXT manifest identifier (ASCII "OTRE").

Definition at line 63 of file chip.h.

◆ CHIP_ROM_EXT_RESIZABLE_SIZE_MAX

#define CHIP_ROM_EXT_RESIZABLE_SIZE_MAX    (CHIP_ROM_EXT_SIZE_MAX + CHIP_BL0_SIZE_MAX)

Definition at line 70 of file chip.h.

◆ CHIP_ROM_EXT_SIZE_MAX

#define CHIP_ROM_EXT_SIZE_MAX   0x10000

Definition at line 69 of file chip.h.

◆ CHIP_ROM_EXT_SIZE_MIN

#define CHIP_ROM_EXT_SIZE_MIN   CHIP_MANIFEST_SIZE

Allowed bounds for the length field of a ROM_EXT manifest.

Definition at line 68 of file chip.h.

◆ PINMUX_PAD_ATTR_PROP_CYCLES

#define PINMUX_PAD_ATTR_PROP_CYCLES   500

Pinmux pull up/down wait delay.

After enabling the pull-up/down on a pin, we need to wait for ~5us for the configuration to propagate to the physical pads. 5us is 500 clock cycles assuming a 100MHz clock.

Definition at line 86 of file chip.h.

◆ SW_STRAP_0_INSEL

#define SW_STRAP_0_INSEL   24

Pinmux MIO input selector values for software strap pins.

Definition at line 98 of file chip.h.

◆ SW_STRAP_0_PAD

#define SW_STRAP_0_PAD   22

Pads of the software strap pins.

Definition at line 105 of file chip.h.

◆ SW_STRAP_0_PERIPH

#define SW_STRAP_0_PERIPH   22

Pinmux peripheral input values for software strap pins.

Definition at line 91 of file chip.h.

◆ SW_STRAP_1_INSEL

#define SW_STRAP_1_INSEL   25

Definition at line 99 of file chip.h.

◆ SW_STRAP_1_PAD

#define SW_STRAP_1_PAD   23

Definition at line 106 of file chip.h.

◆ SW_STRAP_1_PERIPH

#define SW_STRAP_1_PERIPH   23

Definition at line 92 of file chip.h.

◆ SW_STRAP_2_INSEL

#define SW_STRAP_2_INSEL   26

Definition at line 100 of file chip.h.

◆ SW_STRAP_2_PAD

#define SW_STRAP_2_PAD   24

Definition at line 107 of file chip.h.

◆ SW_STRAP_2_PERIPH

#define SW_STRAP_2_PERIPH   24

Definition at line 93 of file chip.h.

◆ SW_STRAP_BOOTSTRAP

#define SW_STRAP_BOOTSTRAP
Value:
((1 << SW_STRAP_2_PERIPH) | (1 << SW_STRAP_1_PERIPH) | \

Bootstrap strap value.

We expect strong pull-ups on all software strap pins, i.e. 11_11_11.

Definition at line 131 of file chip.h.

◆ SW_STRAP_MASK

#define SW_STRAP_MASK
Value:
((1 << SW_STRAP_2_PERIPH) | (1 << SW_STRAP_1_PERIPH) | \

Mask for the software strap pins.

Definition at line 112 of file chip.h.

◆ SW_STRAP_RMA_ENTRY

#define SW_STRAP_RMA_ENTRY
Value:
((1 << SW_STRAP_2_PERIPH) | (1 << SW_STRAP_1_PERIPH) | \

RMA entry strap value.

We expect strong pull-ups on SW_STRAP_2_PERIPH and SW_STRAP_1_PERIPH, and strong pull-down on SW_STRAP_0_PERIPH, i.e. 11_11_00.

Definition at line 122 of file chip.h.

◆ TEST_ROM_IDENTIFIER

#define TEST_ROM_IDENTIFIER   0x54534554

Value written to the end of the retention SRAM creator area by test_rom to be able to determine the type of ROM in tests (ASCII "TEST").

Definition at line 77 of file chip.h.