8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 492f75a commit e0c3584Copy full SHA for e0c3584
common/src/lib.rs
@@ -298,7 +298,7 @@ where
298
let physical_address = PhysAddr::new(ramdisk_address);
299
let ramdisk_physical_start_page: PhysFrame<Size4KiB> =
300
PhysFrame::containing_address(physical_address);
301
- let ramdisk_page_count = system_info.ramdisk_len / Size4KiB::SIZE;
+ let ramdisk_page_count = (system_info.ramdisk_len - 1) / Size4KiB::SIZE;
302
let ramdisk_physical_end_page = ramdisk_physical_start_page + ramdisk_page_count;
303
let start_page = Page::from_start_address(ramdisk_address_start)
304
.expect("the ramdisk start address must be page aligned");
0 commit comments