Unverified Commit fd8713df authored by bors[bot]'s avatar bors[bot] Committed by GitHub
Browse files

Try #618:

parents 50c9ea5f 40e1ba40
Pipeline #866142 passed with stages
in 8 minutes and 15 seconds
......@@ -94,7 +94,7 @@ test:qemu:
-display none -m 64M -serial stdio -enable-kvm
-kernel /usr/local/bin/rusty-loader-x86_64
-initrd rusty-hermit/target/x86_64-unknown-hermit/debug/rusty_demo
- qemu-system-x86_64 -smp 2
- qemu-system-x86_64 -smp 4
-cpu qemu64,apic,fsgsbase,rdtscp,xsave,xsaveopt,fxsr,rdrand
-device isa-debug-exit,iobase=0xf4,iosize=0x04
-display none -m 64M -serial stdio -enable-kvm
......@@ -106,7 +106,7 @@ test:qemu:
-display none -m 64M -serial stdio -enable-kvm
-kernel /usr/local/bin/rusty-loader-x86_64
-initrd rusty-hermit/target/x86_64-unknown-hermit/release/rusty_demo
- qemu-system-x86_64 -smp 2
- qemu-system-x86_64 -smp 4
-cpu qemu64,apic,fsgsbase,rdtscp,xsave,xsaveopt,fxsr,rdrand
-device isa-debug-exit,iobase=0xf4,iosize=0x04
-display none -m 64M -serial stdio -enable-kvm
......
......@@ -111,10 +111,17 @@ pub fn map<S>(
trace!("Mapping {pages:?} to {frames:?} with {flags:?}");
#[cfg(feature = "smp")]
let mut ipi_tlb_flush = false;
for (page, frame) in pages.zip(frames) {
unsafe {
// TODO: Require explicit unmaps
if let Ok((_frame, flush)) = recursive_page_table().unmap(page) {
#[cfg(feature = "smp")]
{
ipi_tlb_flush = true;
}
flush.flush();
}
recursive_page_table()
......@@ -125,7 +132,9 @@ pub fn map<S>(
}
#[cfg(feature = "smp")]
crate::arch::x86_64::kernel::apic::ipi_tlb_flush();
if ipi_tlb_flush {
crate::arch::x86_64::kernel::apic::ipi_tlb_flush();
}
}
pub fn map_heap<S: PageSize>(virt_addr: VirtAddr, count: usize)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment