78,12 → 78,12 |
* its userspace window buffer into DTLB. |
*/ |
ASSERT(THREAD->arch.uspace_window_buffer); |
uintptr_t uw_buf = (uintptr_t) THREAD->arch.uspace_window_buffer; |
uintptr_t uw_buf = ALIGN_DOWN((uintptr_t) THREAD->arch.uspace_window_buffer, PAGE_SIZE); |
if (!overlaps(uw_buf, PAGE_SIZE, base, 1<<KERNEL_PAGE_WIDTH)) { |
/* |
* The buffer is not covered by the 4M locked kernel DTLB entry. |
*/ |
dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, (uintptr_t) uw_buf); |
dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, uw_buf); |
dtlb_insert_mapping(uw_buf, KA2PA(uw_buf), PAGESIZE_8K, true, true); |
} |
|
126,7 → 126,7 |
|
flushw(); /* force all userspace windows into memory */ |
|
uintptr_t uw_buf = (uintptr_t) THREAD->arch.uspace_window_buffer; |
uintptr_t uw_buf = ALIGN_DOWN((uintptr_t) THREAD->arch.uspace_window_buffer, PAGE_SIZE); |
if (!overlaps(uw_buf, PAGE_SIZE, base, 1<<KERNEL_PAGE_WIDTH)) { |
/* |
* The buffer is not covered by the 4M locked kernel DTLB entry |
133,7 → 133,7 |
* and therefore it was given a dedicated locked DTLB entry. |
* Demap it. |
*/ |
dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, (uintptr_t) uw_buf); |
dtlb_demap(TLB_DEMAP_PAGE, TLB_DEMAP_NUCLEUS, uw_buf); |
} |
|
/* sample the state of the userspace window buffer */ |