feat(efuse): Update key purpose table and tests

This commit is contained in:
KonstantinKondrashov
2023-09-12 19:26:01 +08:00
committed by Roland Dobai
parent 3654267765
commit cb5e850934
2 changed files with 3 additions and 12 deletions

View File

@@ -228,17 +228,7 @@ class EspEfuses(base_fields.EspEfusesBase):
raise esptool.FatalError(
"The eFuse supports only xtal=40M (xtal was %d)" % apb_freq
)
self.update_reg(self.REGS.EFUSE_DAC_CONF_REG, self.REGS.EFUSE_DAC_NUM_M, 0xFF)
self.update_reg(
self.REGS.EFUSE_DAC_CONF_REG, self.REGS.EFUSE_DAC_CLK_DIV_M, 0x28
)
self.update_reg(
self.REGS.EFUSE_WR_TIM_CONF1_REG, self.REGS.EFUSE_PWR_ON_NUM_M, 0x3000
)
self.update_reg(
self.REGS.EFUSE_WR_TIM_CONF2_REG, self.REGS.EFUSE_PWR_OFF_NUM_M, 0x190
)
# keep default timing settings
def get_coding_scheme_warnings(self, silent=False):
"""Check if the coding scheme has detected any errors."""
@@ -392,6 +382,7 @@ class EfuseKeyPurposeField(EfuseField):
("SECURE_BOOT_DIGEST0", 9, "DIGEST", None, "no_need_rd_protect"), # SECURE_BOOT_DIGEST0 (Secure Boot key digest)
("SECURE_BOOT_DIGEST1", 10, "DIGEST", None, "no_need_rd_protect"), # SECURE_BOOT_DIGEST1 (Secure Boot key digest)
("SECURE_BOOT_DIGEST2", 11, "DIGEST", None, "no_need_rd_protect"), # SECURE_BOOT_DIGEST2 (Secure Boot key digest)
("KM_INIT_KEY", 12, None, None, "need_rd_protect"), # init key that is used for the generation of AES/ECDSA key
]
# fmt: on
KEY_PURPOSES_NAME = [name[0] for name in KEY_PURPOSES]

View File

@@ -886,7 +886,7 @@ class TestBurnKeyCommands(EfuseTestCase):
BLOCK_KEY0 {IMAGES_DIR}/256bit XTS_AES_256_KEY_1 \
BLOCK_KEY1 {IMAGES_DIR}/256bit_1 XTS_AES_256_KEY_2 \
BLOCK_KEY2 {IMAGES_DIR}/256bit_2 XTS_AES_128_KEY"
if arg_chip in ["esp32c3", "esp32c6", "esp32p4"] or arg_chip in [
if arg_chip in ["esp32c3", "esp32c6"] or arg_chip in [
"esp32h2",
"esp32h2beta1",
]: