The BSOD on boot can be caused by Nvidia drivers.
Info from the Sophos support site:
We’ve identified an issue where some computers may fail to boot and display a Blue Screen of Death (BSOD) with the error UNEXPECTED_KERNEL_MODE_TRAP (0x7F) when certain Nvidia drivers are installed alongside Sophos.
Nvidia has confirmed the problem is on their end and informed us that the issue should be fixed with driver version 582.11
What you can do:
Check for updated Nvidia drivers and install version 582.11
If the issue persists, contact Nvidia Support for further assistance.
As a workaround, uninstall Nvidia drivers and restart your computer to verify the problem is resolved.