diff mbox series

[v9,4/5] xen/riscv: setup initial pagetables

Message ID 6ea28216df1c7f29ebd88e20adb05cdf75af20fe.1685027257.git.oleksii.kurochko@gmail.com (mailing list archive)
State New, archived
Headers show
Series enable MMU for RISC-V | expand

Commit Message

Oleksii Kurochko May 25, 2023, 3:28 p.m. UTC
The patch does two thing:
1. Setup initial pagetables.
2. Enable MMU which end up with code in
   cont_after_mmu_is_enabled()

Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
---
Changes in V9:
 - Nothing changed. Only rebase
---
Changes in V8:
 - Nothing changed. Only rebase
---
Changes in V7:
 - Nothing changed. Only rebase
---
Changes in V6:
 - Nothing changed. Only rebase
---
Changes in V5:
 - Nothing changed. Only rebase
---
Changes in V4:
 - Nothing changed. Only rebase
---
Changes in V3:
 - update the commit message that MMU is also enabled here
 - remove early_printk("All set up\n") as it was moved to
   cont_after_mmu_is_enabled() function after MMU is enabled.
---
Changes in V2:
 * Update the commit message
---
 xen/arch/riscv/setup.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

Comments

Bobby Eshleman May 30, 2023, 9:58 a.m. UTC | #1
On Thu, May 25, 2023 at 06:28:17PM +0300, Oleksii Kurochko wrote:
> The patch does two thing:
> 1. Setup initial pagetables.
> 2. Enable MMU which end up with code in
>    cont_after_mmu_is_enabled()
> 
> Signed-off-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
> ---
> Changes in V9:
>  - Nothing changed. Only rebase
> ---
> Changes in V8:
>  - Nothing changed. Only rebase
> ---
> Changes in V7:
>  - Nothing changed. Only rebase
> ---
> Changes in V6:
>  - Nothing changed. Only rebase
> ---
> Changes in V5:
>  - Nothing changed. Only rebase
> ---
> Changes in V4:
>  - Nothing changed. Only rebase
> ---
> Changes in V3:
>  - update the commit message that MMU is also enabled here
>  - remove early_printk("All set up\n") as it was moved to
>    cont_after_mmu_is_enabled() function after MMU is enabled.
> ---
> Changes in V2:
>  * Update the commit message
> ---
>  xen/arch/riscv/setup.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/xen/arch/riscv/setup.c b/xen/arch/riscv/setup.c
> index 315804aa87..cf5dc5824e 100644
> --- a/xen/arch/riscv/setup.c
> +++ b/xen/arch/riscv/setup.c
> @@ -21,7 +21,10 @@ void __init noreturn start_xen(unsigned long bootcpu_id,
>  {
>      early_printk("Hello from C env\n");
>  
> -    early_printk("All set up\n");
> +    setup_initial_pagetables();
> +
> +    enable_mmu();
> +
>      for ( ;; )
>          asm volatile ("wfi");
>  
> -- 
> 2.40.1
> 
> 

Acked-by: Bobby Eshleman <bobbyeshleman@gmail.com>
diff mbox series

Patch

diff --git a/xen/arch/riscv/setup.c b/xen/arch/riscv/setup.c
index 315804aa87..cf5dc5824e 100644
--- a/xen/arch/riscv/setup.c
+++ b/xen/arch/riscv/setup.c
@@ -21,7 +21,10 @@  void __init noreturn start_xen(unsigned long bootcpu_id,
 {
     early_printk("Hello from C env\n");
 
-    early_printk("All set up\n");
+    setup_initial_pagetables();
+
+    enable_mmu();
+
     for ( ;; )
         asm volatile ("wfi");