Download-Link: sourceforge.net/projects/grub4dosahcipatch
Grub4DOS AHCI / NVMe speed patch for memory maps
This package includes the following directories:
- bin -> compiled grldr version 0.4.5c with AHCI / NVMe support
- patch -> ahcinvme.patch for updating stock grub 0.4.5c source code
- src -> all changed and additional source code files used with grub 0.4.5c
The AHCI and NVMe support can be enabled by using the additional grub menu commands "ahci"
and "nvme". We can set the following parameters with the new commands:
ahci --set-drive=DRIVE --set-controller=CONTR --set-port=PORT [--showall] [--showselected]
nvme --set-drive=DRIVE --set-controller=CONTR [--showall] [--showselected]
Using these commands searches PCI configuration space for all present AHCI / NVMe controllers.
After setting this option every read to DRIVE is redirected to the selected AHCI / NVMe
controller. The CONTR and PORT arguments start at zero, where 0 corresponds to the 1st present
AHCI / NVMe controller / port found. If the option --showall is used, all AHCI / NVMe
controllers, ports and connected devices are displayed. If the option --showselected is used,
the selected AHCI / NVMe controller, port and connected device is displayed. The argument
--uninit uninitializes all AHCI / NVMe controllers. This command was implemented to speed up
transfer rates if an image file is loaded from an AHCI / NVMe SSD and mapped to RAM.
The AHCI / NVMe support can not be disabled anymore during compile with the configure command.
We removed this feature to make the code simpler.
The standard read block size is now always 32 MB, because this is the maximum data transfer
size we can get from an AHCI hard disk device at issuing one read command. If an image file
is mapped to RAM we get a speed of 550 MB/s with a Samsung 840 Pro SSD and 3 GB/s for a
Samsung 960 EVO NVMe SSD.
Pay attention that this AHCI / NVMe addition is only useful if you load the images from SSD to RAM.
Loading a disk image directly or using a normal platter HDD does not increase the read speed much.
Use this patch with care on your own risk!
Because we added some parameters to the AHCI and NVMe command line we wanna show you two sample
menu entries for both RAM disk mappings:
title Win10 - RAMDISK AHCI
ahci --set-drive=0x80 --set-controller=0 --set-port=0 --showselected
find --set-root --ignore-floppies /win10.vhd
map --mem /win10.vhd (hd0)
map --hook
ahci --uninit
root (hd0,0)
chainloader /bootmgr
title Win10 - RAMDISK NVMe
nvme --set-drive=0x80 --set-controller=0 --showselected
find --set-root --ignore-floppies /win10.vhd
map --mem /win10.vhd (hd0)
map --hook
nvme --uninit
root (hd0,0)
chainloader /bootmgr
You should always include the new "--uninit" parameter directly after the "map --hook" command.
This stops the redirection of drive 0x80 (hd0) to the AHCI / NVMe read procedure. The drive
number should always match the real BIOS drive number for the system, otherwise the system may
hang.
Many thanks to all the developers and forum members of reboot pro for making it possible to boot
a full-sized Windows from RAM and harddisk image.
Greets
Kai Schtrom