MCPcopy Create free account
hub / github.com/F-Stack/f-stack / pl310_inv_range

Function pl310_inv_range

freebsd/arm/arm/pl310.c:367–391  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

365}
366
367static void
368pl310_inv_range(vm_paddr_t start, vm_size_t size)
369{
370
371 if ((pl310_softc == NULL) || !pl310_softc->sc_enabled)
372 return;
373
374 PL310_LOCK(pl310_softc);
375 if (start & g_l2cache_align_mask) {
376 size += start & g_l2cache_align_mask;
377 start &= ~g_l2cache_align_mask;
378 }
379 if (size & g_l2cache_align_mask) {
380 size &= ~g_l2cache_align_mask;
381 size += g_l2cache_line_size;
382 }
383 while (size > 0) {
384 pl310_write4(pl310_softc, PL310_INV_LINE_PA, start);
385 start += g_l2cache_line_size;
386 size -= g_l2cache_line_size;
387 }
388
389 pl310_cache_sync();
390 PL310_UNLOCK(pl310_softc);
391}
392
393static void
394pl310_drain_writebuf(void)

Callers

nothing calls this directly

Calls 2

pl310_write4Function · 0.85
pl310_cache_syncFunction · 0.85

Tested by

no test coverage detected