Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-20 Thread via GitHub
xiaoxiang781216 merged PR #12353: URL: https://github.com/apache/nuttx/pull/12353 -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@nu

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-19 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1606243285 ## arch/arm64/Kconfig: ## @@ -146,14 +146,13 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 is not

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-19 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1606241189 ## arch/arm64/src/common/arm64_boot.c: ## @@ -78,7 +78,7 @@ void arm64_boot_el3_init(void) reg = 0U; /* Reset */ reg |= SCR_NS_BIT; /* EL2 / E

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-19 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1606241479 ## arch/arm64/src/common/arm64_mmu.c: ## @@ -523,6 +523,40 @@ static void setup_page_tables(void) } } +#ifdef CONFIG_ARCH_BOOT_EL3 +static void enable_mmu_el3(

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-18 Thread via GitHub
xiaoxiang781216 commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1605812341 ## arch/arm64/src/common/arm64_boot.c: ## @@ -78,7 +78,7 @@ void arm64_boot_el3_init(void) reg = 0U; /* Reset */ reg |= SCR_NS_BIT; /*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-18 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1605809960 ## arch/arm64/src/common/arm64_boot.c: ## @@ -78,7 +78,7 @@ void arm64_boot_el3_init(void) reg = 0U; /* Reset */ reg |= SCR_NS_BIT; /* EL2 / E

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-18 Thread via GitHub
xiaoxiang781216 commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1605798562 ## arch/arm64/src/common/arm64_boot.c: ## @@ -78,7 +78,7 @@ void arm64_boot_el3_init(void) reg = 0U; /* Reset */ reg |= SCR_NS_BIT; /*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-17 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604501943 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 is not a

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-17 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604486596 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604402742 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 is not a

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604400226 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -111,7 +136,9 @@ void arm64_chip_boot(void) #endif #if defined(CONFIG_SMP) || defined(CONFIG_ARCH_HAVE_PSCI) +#ifndef CON

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604381093 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/***

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604381093 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/***

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
xiaoxiang781216 commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604332795 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 i

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
xiaoxiang781216 commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604332795 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 i

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1604326478 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 is not a

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602650342 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-16 Thread via GitHub
xiaoxiang781216 commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1603541618 ## arch/arm64/Kconfig: ## @@ -146,6 +146,15 @@ config ARCH_HAVE_EL3 runing at EL3 is not necessary and system register for EL3 i

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602712403 ## boards/arm64/imx9/imx93-evk/scripts/Make.defs: ## @@ -20,9 +20,14 @@ include $(TOPDIR)/.config include $(TOPDIR)/tools/Config.mk +include $(TOPDIR)/tools/imx9/C

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602649023 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -111,7 +136,9 @@ void arm64_chip_boot(void) #endif #if defined(CONFIG_SMP) || defined(CONFIG_ARCH_HAVE_PSCI) +#ifndef CON

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602647805 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602639089 ## boards/arm64/imx9/imx93-evk/scripts/ocramboot.ld: ## @@ -0,0 +1,155 @@ +/ + * boards/arm

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1602638748 ## arch/arm64/src/common/arm64_gicv3.c: ## @@ -789,6 +789,28 @@ uint64_t * arm64_decodefiq(uint64_t * regs) irq = arm64_gic_get_active_fiq(); +#ifdef CONFIG_ARC

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
acassis commented on PR #12353: URL: https://github.com/apache/nuttx/pull/12353#issuecomment-2113325012 @pussuw could you please take a look at those CI errors on imx9: "nuttx/tools/imx9/Config.mk: No such file or directory" -- This is an automated message from the Apache Git Service. To

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601980787 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/***

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601915922 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -111,7 +136,9 @@ void arm64_chip_boot(void) #endif #if defined(CONFIG_SMP) || defined(CONFIG_ARCH_HAVE_PSCI) +#ifndef CON

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601914481 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601881397 ## boards/arm64/imx9/imx93-evk/scripts/ocramboot.ld: ## @@ -0,0 +1,155 @@ +/ + * boards/arm64

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601880174 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -111,7 +136,9 @@ void arm64_chip_boot(void) #endif #if defined(CONFIG_SMP) || defined(CONFIG_ARCH_HAVE_PSCI) +#ifndef CONFI

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601878364 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/***

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
pussuw commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601876575 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/***

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601605844 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601647705 ## arch/arm64/src/common/arm64_gicv3.c: ## @@ -789,6 +789,28 @@ uint64_t * arm64_decodefiq(uint64_t * regs) irq = arm64_gic_get_active_fiq(); +#ifdef CONFIG_ARC

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
acassis commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601642973 ## arch/arm64/src/common/arm64_gicv3.c: ## @@ -789,6 +789,28 @@ uint64_t * arm64_decodefiq(uint64_t * regs) irq = arm64_gic_get_active_fiq(); +#ifdef CONFIG_ARCH

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601616761 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601613068 ## arch/arm64/src/common/arm64_mmu.c: ## @@ -556,6 +556,41 @@ static void enable_mmu_el1(unsigned int flags) #endif } +#ifdef CONFIG_ARCH_HAVE_EL3 Review Comment:

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on PR #12353: URL: https://github.com/apache/nuttx/pull/12353#issuecomment-2112469769 Added a few comments, otherwise looks good. Nice work! -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL ab

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601588726 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601605844 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601584026 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601602021 ## boards/arm64/imx9/imx93-evk/scripts/ocramboot.ld: ## @@ -0,0 +1,155 @@ +/ + * boards/arm

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601595434 ## arch/arm64/src/imx9/Kconfig: ## @@ -47,6 +47,14 @@ config IMX9_FLEXIO_PWM select PWM_MULTICHAN default n +config IMX9_BOOTLOADER + bool "Boo

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601593274 ## boards/arm64/imx9/imx93-evk/scripts/ocramboot.ld: ## @@ -0,0 +1,155 @@ +/ + * boards/arm

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601588726 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601588726 ## arch/arm64/src/imx9/imx9_boot.c: ## @@ -44,19 +44,39 @@ #include "imx9_gpio.h" #include "imx9_lowputc.h" +/*

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601586955 ## arch/arm64/src/imx9/Kconfig: ## @@ -47,6 +47,14 @@ config IMX9_FLEXIO_PWM select PWM_MULTICHAN default n +config IMX9_BOOTLOADER + bool "Boo

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601584026 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601581966 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

Re: [PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
jlaitine commented on code in PR #12353: URL: https://github.com/apache/nuttx/pull/12353#discussion_r1601578603 ## arch/arm64/src/common/arm64_head.S: ## @@ -235,6 +235,15 @@ switch_el: blarm64_boot_el3_init +#ifdef CONFIG_ARCH_BOOT_EL3 +msr SPSel, #1 + +/

[PR] arm64 EL3 runtime support [nuttx]

2024-05-15 Thread via GitHub
eenurkka opened a new pull request, #12353: URL: https://github.com/apache/nuttx/pull/12353 ## Summary This introduces EL3 support for NuttX meaning it may run from EL3 without dropping privileges. It's useful when it replaces an existing bootloader, such as SPL (from SPL/U-boot comb