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

Function free_pv_chunk

freebsd/mips/mips/pmap.c:1600–1614  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1598}
1599
1600static void
1601free_pv_chunk(struct pv_chunk *pc)
1602{
1603 vm_page_t m;
1604
1605 TAILQ_REMOVE(&pv_chunks, pc, pc_lru);
1606 PV_STAT(pv_entry_spare -= _NPCPV);
1607 PV_STAT(pc_chunk_count--);
1608 PV_STAT(pc_chunk_frees++);
1609 /* entire chunk is free, return it */
1610 m = PHYS_TO_VM_PAGE(MIPS_DIRECT_TO_PHYS((vm_offset_t)pc));
1611 dump_drop_page(m->phys_addr);
1612 vm_page_unwire_noq(m);
1613 vm_page_free(m);
1614}
1615
1616/*
1617 * get a new pv_entry, allocating a block from the system

Callers 2

free_pv_entryFunction · 0.70
pmap_remove_pagesFunction · 0.70

Calls 4

PHYS_TO_VM_PAGEFunction · 0.85
dump_drop_pageFunction · 0.85
vm_page_unwire_noqFunction · 0.85
vm_page_freeFunction · 0.85

Tested by

no test coverage detected