This is an automated email from the ASF dual-hosted git repository. vipulrahane pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/mynewt-core.git
The following commit(s) were added to refs/heads/master by this push: new 5c84ed7 hw/mcu/nrf5340: Add APPROTECT user handling syscfg new ae153db Merge pull request #2614 from vrahane/nrf5340_revA_errata26 5c84ed7 is described below commit 5c84ed79bda2462be84f81bd4ad5eaebd23271b0 Author: vrahane <vi...@proxy.com> AuthorDate: Tue Jun 8 21:56:35 2021 -0700 hw/mcu/nrf5340: Add APPROTECT user handling syscfg - As per Errata 26, CTRL-AP: APPROTECT.DISABLE and SECUREAPPROTECT.DISABLE registers are not functional - So we need to conditionally disable its usage - The syscfg can also be used for user handling of APPROTECT, hence making it generic. --- hw/mcu/nordic/nrf5340/pkg.yml | 3 +++ hw/mcu/nordic/nrf5340/syscfg.yml | 9 ++++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/hw/mcu/nordic/nrf5340/pkg.yml b/hw/mcu/nordic/nrf5340/pkg.yml index 161e0bc..4ffbaec 100644 --- a/hw/mcu/nordic/nrf5340/pkg.yml +++ b/hw/mcu/nordic/nrf5340/pkg.yml @@ -104,3 +104,6 @@ pkg.deps.I2C_3': pkg.deps.NRF5340_EMBED_NET_CORE: - "@apache-mynewt-core/hw/mcu/nordic/nrf5340/net_core_image" + +pkg.cflags.MCU_NRF5340_EN_APPROTECT_USERHANDLING: + - "-DENABLE_APPROTECT_USER_HANDLING" diff --git a/hw/mcu/nordic/nrf5340/syscfg.yml b/hw/mcu/nordic/nrf5340/syscfg.yml index 94a14af..9a07ebb 100644 --- a/hw/mcu/nordic/nrf5340/syscfg.yml +++ b/hw/mcu/nordic/nrf5340/syscfg.yml @@ -25,13 +25,14 @@ syscfg.defs: - $notnull choices: - nRF5340_APP + MCU_APP_CORE: description: > Constant value always set to 1. It allows to have common packages for network and application core that do have some differences depending on which core they are build for. value: 1 - restriction: MCU_NET_CORE==0 + MCU_FLASH_MIN_WRITE_SIZE: description: > Specifies the required alignment for internal flash writes. @@ -89,6 +90,12 @@ syscfg.defs: Default value is 0, so disabled. value: 0 + MCU_NRF5340_EN_APPROTECT_USERHANDLING: + description: > + This needs to be set by the BSP/App/Target if the + MCU/BSP wants to handle APPROTECT on its own. + value: 0 + # MCU peripherals definitions ADC_0: description: 'Enable nRF5340 ADC 0'