diff options
author | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-08-29 02:25:44 +0200 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-08-29 02:25:44 +0200 |
commit | bb1537d4ede45eda2d2dcdd6521b20a59a8ea3f4 (patch) | |
tree | e506282a81ea3ed9eb4d134d848d12ea3e3e695b /vm | |
parent | 247031c88d56028d8f6ea888bb28f20a96aafbc2 (diff) | |
download | gnumach-bb1537d4ede45eda2d2dcdd6521b20a59a8ea3f4.tar.gz gnumach-bb1537d4ede45eda2d2dcdd6521b20a59a8ea3f4.tar.bz2 gnumach-bb1537d4ede45eda2d2dcdd6521b20a59a8ea3f4.zip |
vm_page: Fix setting higher bits in physical addresses
Diffstat (limited to 'vm')
-rw-r--r-- | vm/vm_page.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/vm/vm_page.c b/vm/vm_page.c index 8e5cab38..7220dffb 100644 --- a/vm/vm_page.c +++ b/vm/vm_page.c @@ -427,7 +427,7 @@ vm_page_seg_free_to_buddy(struct vm_page_seg *seg, struct vm_page *page, pa = page->phys_addr; while (order < (VM_PAGE_NR_FREE_LISTS - 1)) { - buddy_pa = pa ^ vm_page_ptoa(1 << order); + buddy_pa = pa ^ vm_page_ptoa(1ULL << order); if ((buddy_pa < seg->start) || (buddy_pa >= seg->end)) break; @@ -440,7 +440,7 @@ vm_page_seg_free_to_buddy(struct vm_page_seg *seg, struct vm_page *page, vm_page_free_list_remove(&seg->free_lists[order], buddy); buddy->order = VM_PAGE_ORDER_UNLISTED; order++; - pa &= -vm_page_ptoa(1 << order); + pa &= -vm_page_ptoa(1ULL << order); page = &seg->pages[vm_page_atop(pa - seg->start)]; } |