}
static void __init alloc_init_pud(pgd_t *pgd, unsigned long addr,
- unsigned long end, unsigned long phys, const struct mem_type *type,
- bool force_pages)
+ unsigned long end, phys_addr_t phys,
- const struct mem_type *type)
++ const struct mem_type *type, bool force_pages)
{
pud_t *pud = pud_offset(pgd, addr);
unsigned long next;
tst rh, #1 << (57 - 32) @ L_PTE_NONE
bicne rl, #L_PTE_VALID
bne 1f
- tst rh, #1 << (55 - 32) @ L_PTE_DIRTY
- orreq rl, #L_PTE_RDONLY
+
+ eor ip, rh, #1 << (55 - 32) @ toggle L_PTE_DIRTY in temp reg to
+ @ test for !L_PTE_DIRTY || L_PTE_RDONLY
+ tst ip, #1 << (55 - 32) | 1 << (58 - 32)
+ orrne rl, #PTE_AP2
+ biceq rl, #PTE_AP2
+
1: strd r2, r3, [r0]
ALT_SMP(W(nop))
+#ifdef CONFIG_ARM_ERRATA_824069
+ ALT_UP (mcr p15, 0, r0, c7, c14, 1) @ flush_pte
+#else
ALT_UP (mcr p15, 0, r0, c7, c10, 1) @ flush_pte
+#endif
#endif
mov pc, lr
ENDPROC(cpu_v7_set_pte_ext)