The short answer is “both”. Many problems can prevent your PC from detecting or using a boot device, ranging from a misconfigured BIOS/UEFI (software-related) to an old failing HDD (hardware-related).