Skip to content

Commit

Permalink
arm: armv8 correct value passed to __asm_dcache_all
Browse files Browse the repository at this point in the history
>From source code comments:
"x0: 0 flush & invalidate, 1 invalidate only"

Current value 0xffff can make invalidate work, since we only judge whether
input value is 0 or not, see following code:
"
    tbz     w1, #0, 1f
    dc      isw, x9
    b       2f
1:  dc      cisw, x9      /* clean & invalidate by set/way */
2:  subs    x6, x6, #1    /* decrement the way */
"

Later we may add "2 clean only" support. So following the comments,
correct value from 0xffff to 1.

Signed-off-by: Peng Fan <[email protected]>
Cc: York Sun <[email protected]>
Cc: Albert Aribaud <[email protected]>
  • Loading branch information
Peng Fan authored and albert-aribaud-u-boot committed Sep 12, 2015
1 parent ed64190 commit 208bd51
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion arch/arm/cpu/armv8/cache.S
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ ENDPROC(__asm_flush_dcache_all)

ENTRY(__asm_invalidate_dcache_all)
mov x16, lr
mov x0, #0xffff
mov x0, #0x1
bl __asm_dcache_all
mov lr, x16
ret
Expand Down

0 comments on commit 208bd51

Please sign in to comment.