diff options
author | kmacy <kmacy@FreeBSD.org> | 2006-12-24 01:56:35 +0000 |
---|---|---|
committer | kmacy <kmacy@FreeBSD.org> | 2006-12-24 01:56:35 +0000 |
commit | 8e846a84a40de00567b5dc5d32a588dd850a7674 (patch) | |
tree | ee2ad755ab893cc8034a12c912c995eec1f5c2e4 /sys/sun4v | |
parent | f51b738f57f9c5d4072b6be007a3e21615f56e3d (diff) | |
download | FreeBSD-src-8e846a84a40de00567b5dc5d32a588dd850a7674.zip FreeBSD-src-8e846a84a40de00567b5dc5d32a588dd850a7674.tar.gz |
- resizing the tte_hash in pmap_copy is not likely to occur
- the implementation also made the mistake of assuming the
dst_pmap is the current pmap
Diffstat (limited to 'sys/sun4v')
-rw-r--r-- | sys/sun4v/sun4v/pmap.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/sys/sun4v/sun4v/pmap.c b/sys/sun4v/sun4v/pmap.c index 20651ce..e277a08 100644 --- a/sys/sun4v/sun4v/pmap.c +++ b/sys/sun4v/sun4v/pmap.c @@ -972,7 +972,6 @@ pmap_copy(pmap_t dst_pmap, pmap_t src_pmap, vm_offset_t dst_addr, vm_offset_t addr, end_addr; end_addr = src_addr + len; - /* * Don't let optional prefaulting of pages make us go * way below the low water mark of free pages or way @@ -1008,14 +1007,14 @@ pmap_copy(pmap_t dst_pmap, pmap_t src_pmap, vm_offset_t dst_addr, } } } - PMAP_UNLOCK(src_pmap); - - if (tte_hash_needs_resize(dst_pmap->pm_hash)) - pmap_tte_hash_resize(dst_pmap); sched_unpin(); vm_page_unlock_queues(); + PMAP_UNLOCK(src_pmap); PMAP_UNLOCK(dst_pmap); + + + } void @@ -1584,6 +1583,7 @@ pmap_invalidate_all(pmap_t pmap) boolean_t pmap_is_modified(vm_page_t m) { + return (tte_get_phys_bit(m, VTD_W)); } @@ -1827,6 +1827,11 @@ pmap_qenter(vm_offset_t sva, vm_page_t *m, int count) va = sva; while (count-- > 0) { + /* + * If we make explicit calls to tte_hash_update + * we can determine if any of the pages have been mapped + * before - this can save us a pmap_invalidate_range + */ pmap_kenter(va, VM_PAGE_TO_PHYS(*m)); va += PAGE_SIZE; m++; |