]> git.sur5r.net Git - u-boot/blobdiff - arch/arm/cpu/armv8/cache_v8.c
SPDX: Convert all of our single license tags to Linux Kernel style
[u-boot] / arch / arm / cpu / armv8 / cache_v8.c
index bd1c3e0335d4630f8367581fb88a864a0964b621..038405173eb13493659a58508c2a69639013d359 100644 (file)
@@ -1,11 +1,10 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * (C) Copyright 2013
  * David Feng <fenghua@phytium.com.cn>
  *
  * (C) Copyright 2016
  * Alexander Graf <agraf@suse.de>
- *
- * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
@@ -230,7 +229,10 @@ static void add_map(struct mm_region *map)
                                /* Page fits, create block PTE */
                                debug("Setting PTE %p to block virt=%llx\n",
                                      pte, virt);
-                               *pte = phys | attrs;
+                               if (level == 3)
+                                       *pte = phys | attrs | PTE_TYPE_PAGE;
+                               else
+                                       *pte = phys | attrs;
                                virt += blocksize;
                                phys += blocksize;
                                size -= blocksize;
@@ -446,7 +448,7 @@ inline void flush_dcache_all(void)
  */
 void invalidate_dcache_range(unsigned long start, unsigned long stop)
 {
-       __asm_flush_dcache_range(start, stop);
+       __asm_invalidate_dcache_range(start, stop);
 }
 
 /*