The issue is, when doing sudo, you have to put in the password when doing sudo. In this case, you put in your password, some flag is set, the computer does a full reset, and then after it reads the flag and decides to bypass the password system. That sounds like just a step away of figuring out how to set this flag without a password to bypass logging in.
Here’s what you need for Arch, for more context: https://wiki.archlinux.org/title/AMDGPU