summaryrefslogtreecommitdiff
path: root/src/libultra/os/writebackdcacheall.s
blob: 432b3b05ead304f816613f7c2eafe2961efdd397 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include "PR/asm.h"
#include "PR/regdef.h"
#include "PR/R4300.h"

.text

LEAF(osWritebackDCacheAll)
    li      t0, K0BASE
    li      t2, DCACHE_SIZE
    addu    t1, t0, t2
    addu    t1, t1, -DCACHE_LINESIZE
1:
    CACHE(  (CACH_PD | C_IWBINV), (t0))
.set noreorder
    bltu    t0, t1, 1b
     addu   t0, DCACHE_LINESIZE
.set reorder
    jr      ra
END(osWritebackDCacheAll)