* This routine tears out page mappings from the * kernel -- it is meant only for temporary mappings. */
| 1596 | * kernel -- it is meant only for temporary mappings. |
| 1597 | */ |
| 1598 | void |
| 1599 | pmap_qremove(vm_offset_t sva, int count) |
| 1600 | { |
| 1601 | pt_entry_t *pte; |
| 1602 | vm_offset_t va; |
| 1603 | int lvl; |
| 1604 | |
| 1605 | KASSERT(sva >= VM_MIN_KERNEL_ADDRESS, ("usermode va %lx", sva)); |
| 1606 | |
| 1607 | va = sva; |
| 1608 | while (count-- > 0) { |
| 1609 | pte = pmap_pte(kernel_pmap, va, &lvl); |
| 1610 | KASSERT(lvl == 3, |
| 1611 | ("Invalid device pagetable level: %d != 3", lvl)); |
| 1612 | if (pte != NULL) { |
| 1613 | pmap_clear(pte); |
| 1614 | } |
| 1615 | |
| 1616 | va += PAGE_SIZE; |
| 1617 | } |
| 1618 | pmap_invalidate_range(kernel_pmap, sva, va); |
| 1619 | } |
| 1620 | |
| 1621 | /*************************************************** |
| 1622 | * Page table page management routines..... |
nothing calls this directly
no test coverage detected