Skip to content

Commit

Permalink
risc-v/mpfs: add tamper detection support
Browse files Browse the repository at this point in the history
This adds support for detecting various tamper events.
The interrupt handler makes noise at every detection.

Perhaps easiest test is to attach JTAG debugger.

TAMPER_TESTS -define has some nonexisting (not in repos)
calls, perhaps could remove it alltogether.

Signed-off-by: Eero Nurkkala <[email protected]>
  • Loading branch information
eenurkka committed Nov 9, 2023
1 parent a18cb51 commit a1ce026
Show file tree
Hide file tree
Showing 4 changed files with 492 additions and 0 deletions.
6 changes: 6 additions & 0 deletions arch/risc-v/src/mpfs/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -426,6 +426,12 @@ config MPFS_COREMMC_IRQNUM
range 0 63
depends on MPFS_COREMMC

config MPFS_TAMPER
bool "Tamper detection"
default n
---help---
Enable tamper detection mechanisms.

config MPFS_IHC_CLIENT
bool "IHC slave"
depends on RPTUN && !MPFS_BOOTLOADER
Expand Down
4 changes: 4 additions & 0 deletions arch/risc-v/src/mpfs/Make.defs
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,10 @@ ifeq ($(CONFIG_MPFS_CORESPI),y)
CHIP_CSRCS += mpfs_corespi.c
endif

ifeq ($(CONFIG_MPFS_TAMPER),y)
CHIP_CSRCS += mpfs_tamper.c
endif

ifeq ($(CONFIG_MPFS_CRYPTO),y)
include mpfs/crypto.defs
endif
Loading

0 comments on commit a1ce026

Please sign in to comment.