Changes

730 bytes added ,  06:46, 31 August 2019
Line 305: Line 305:  
     return (smc_get_config(ConfigItem_KernelConfiguration) >> 3) & 1;
 
     return (smc_get_config(ConfigItem_KernelConfiguration) >> 3) & 1;
 
</pre>
 
</pre>
 +
 +
== KernelLdr_EnsureCacheFlushed ==
 +
 +
Note: this is inlined, however it uses instructions that no compiler has intrinsics for (and looks like hand-written asm), so it's presumably its own thing.
 +
 +
<pre>
 +
    // Invalidate Local Cache
 +
    KernelLdr_InvalidateCacheLocal();
 +
    __dsb_sy();
 +
 +
    // Invalidate Share
 +
    KernelLdr_InvalidateCacheShared();
 +
    __dsb_sy();
 +
 +
    // Invalidate Local Cache again
 +
    KernelLdr_InvalidateCacheLocal();
 +
    __dsb_sy();
 +
   
 +
    // asm { tlbi vmallelis; }
 +
    __dsb_sy();
 +
    __isb();
 +
</pre>
 +
 +
== KernelLdr_InvalidateCacheLocal ==
 +
 +
Standard ARM cache clean code, uses LoUIS from CLIDR_EL1.
 +
 +
== KernelLdr_InvalidateCacheShared ==
 +
 +
Standard ARM cache clean code, uses LoUIS  + LoC from CLIDR_EL1.
    
== KInitialPageAllocator::KInitialPageAllocator ==
 
== KInitialPageAllocator::KInitialPageAllocator ==