Changeset 93d8022 in mainline
- Timestamp:
- 2015-10-26T21:12:57Z (9 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 5783d10
- Parents:
- 1a2a6e7
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
boot/arch/arm32/src/mm.c
r1a2a6e7 r93d8022 143 143 pte->should_be_zero_1 = 0; 144 144 pte->access_permission_0 = PTE_AP_USER_NO_KERNEL_RW; 145 #if def PROCESSOR_ARCH_armv7_a145 #if defined(PROCESSOR_ARCH_armv6) || defined(PROCESSOR_ARCH_armv7_a) 146 146 /* 147 147 * Keeps this setting in sync with memory type attributes in: … … 152 152 pte->tex = section_cacheable(frame) ? 5 : 0; 153 153 pte->cacheable = section_cacheable(frame) ? 0 : 0; 154 pte->bufferable = section_cacheable(frame) ? 1 : 0;154 pte->bufferable = section_cacheable(frame) ? 1 : 1; 155 155 #else 156 pte->bufferable = 1;156 pte->bufferable = section_cacheable(frame); 157 157 pte->cacheable = section_cacheable(frame); 158 158 pte->tex = 0; -
kernel/arch/arm32/include/arch/cache.h
r1a2a6e7 r93d8022 46 46 void cpu_dcache_flush_invalidate(void); 47 47 extern void icache_invalidate(void); 48 extern void dcache_invalidate(void); 48 49 extern void dcache_clean_mva_pou(uintptr_t); 49 50 -
kernel/arch/arm32/include/arch/mm/page_armv6.h
r1a2a6e7 r93d8022 257 257 if (flags & PAGE_CACHEABLE) { 258 258 /* 259 * Write-through, write-allocate memory, see ch. B3.8.2 260 * (p. B3-1358) of ARM Architecture reference manual. 259 * Outer and inner write-back, write-allocate memory, 260 * see ch. B3.8.2 (p. B3-1358) of ARM Architecture reference 261 * manual. 262 * 261 263 * Make sure the memory type is correct, and in sync with: 262 264 * init_boot_pt (boot/arch/arm32/src/mm.c) … … 277 279 } 278 280 279 #if defined(PROCESSOR_ARCH_armv6)280 /* FIXME: this disables caches */281 p->shareable = 1;282 #else283 281 /* Shareable is ignored for devices (non-cacheable), 284 282 * turn it off for normal memory. */ 285 283 p->shareable = 0; 286 #endif287 284 288 285 p->non_global = !(flags & PAGE_GLOBAL); -
kernel/arch/arm32/src/cpu/cpu.c
r1a2a6e7 r93d8022 130 130 { 131 131 uint32_t control_reg = SCTLR_read(); 132 132 133 dcache_invalidate(); 134 read_barrier(); 135 133 136 /* Turn off tex remap, RAZ/WI prior to armv7 */ 134 137 control_reg &= ~SCTLR_TEX_REMAP_EN_FLAG; … … 341 344 #endif 342 345 346 void dcache_invalidate(void) 347 { 348 #if defined(PROCESSOR_ARCH_armv7_a) 349 dcache_flush_invalidate(); 350 #else 351 if (cache_is_unified()) 352 CIALL_write(0); 353 else 354 DCIALL_write(0); 355 #endif 356 } 357 343 358 void dcache_clean_mva_pou(uintptr_t mva) 344 359 {
Note:
See TracChangeset
for help on using the changeset viewer.