As you can access Ubuntu, open a terminal and enter:-

sudo systemctl reboot --firmware-setup
While in your firmware settings, disable Secure Boot, Fast Boot , TPM and other security features.
...