]> xenbits.xensource.com Git - unikraft/unikraft.git/commitdiff
plat/kvm/arm: Do not clean & invalidate the cache after enabling the MMU
authorMichalis Pappas <michalis@unikraft.io>
Thu, 13 Jul 2023 11:07:13 +0000 (13:07 +0200)
committerUnikraft <monkey@unikraft.io>
Tue, 15 Aug 2023 19:23:41 +0000 (19:23 +0000)
To maximize boot performance we only invalidate the cache for regions
accessed before enabling the MMU. This makes the clean & invalidate
step of the entire image region after enabling the MMU redundant.

Signed-off-by: Michalis Pappas <michalis@unikraft.io>
Reviewed-by: Sergiu Moga <sergiu@unikraft.io>
Approved-by: Razvan Deaconescu <razvand@unikraft.io>
Tested-by: Unikraft CI <monkey@unikraft.io>
GitHub-Closes: #1049

plat/kvm/arm/pagetable64.S

index 21e1a5a6e4359d56f7374bc8d49e5bab4898c3b9..8cfc46f7eac839e41eee5df73730f713e621ac40 100644 (file)
@@ -95,18 +95,6 @@ setup_tcr_el1:
        /* save lr */
        mov x22, x30
 
-        /*
-        * Invalidate the D-Cache to avoid using invalid data that existed
-        * in D-Cache. Invalidate ranges that may have been modified:
-        * DATA, BSS, PAGETABLE and BOOTSTACK.
-        */
-       ur_ldr  x0, _data
-       ur_ldr  x1, _end
-
-       add x1, x1, #__STACK_SIZE
-       sub x1, x1, x0
-       bl clean_and_invalidate_dcache_range
-
        /* Setup SCTLR */
        ldr x2, =SCTLR_SET_BITS
        ldr x3, =SCTLR_CLEAR_BITS