Check these keys for Intel chipset, set to 0
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Msahci\Start
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\IastorV\Start
Changing from RAID to AHCI, you may need one more step. Msahci driver requires Atapi.sys miniport to be loaded during boot as well.
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\atapi\Start
For AMD chipsets
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\nvstor\Start
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\nvraid\Start
HKEY_LOCAL_MACHINE\System\CurrentControlSet\Services\amdsata\Start (non raid)
If You are not able to boot up thanks to BSOD
, try out booting to Safe Mode
and setting those Registry keys.