(EE) NVIDIA(0): Failed to enter VT (mode initialization failed) with "Load legacy option rom&qu

When the machine wakes up from suspend, and “load legacy option rom” is disabled in bios setup, X server terminates with following error at the end of log:

[ 63799.606] (II) NVIDIA(0): Setting mode "DP-2: nvidia-auto-select @3840x2160 +0+0 {ViewPortIn=3840x2160, ViewPortOut=3840x2160+0+0}"
[ 63799.607] (WW) NVIDIA(0): Failed to set the display configuration
[ 63799.607] (WW) NVIDIA(0):  - Setting a mode on head 0 failed: An invalid mode was
[ 63799.607] (WW) NVIDIA(0):     requested
[ 63799.607] (EE) NVIDIA(0): Failed to enter VT (mode initialization failed)
[ 63799.607] (EE) 
Fatal server error:
[ 63799.607] (EE) EnterVT failed for screen 0
[ 63799.607] (EE) 
[ 63799.607] (EE)

Instead of session unlock screen I see login screen of the display manager (and, obviously, it logs in to a clean new session).

The hardware is Alienware X51 R2 (GeForce GTX 960). Dell P2415Q display is attached through DisplayPort.

On Windows, the same machine, and the same display works without any major issues.

nvidia-bug-report.log.gz: https://drive.google.com/file/d/0B3XnWl6KJ-NOdFUxT0htU05PVjQ/view?usp=sharing
Xorg.0.log.old: https://drive.google.com/file/d/0B3XnWl6KJ-NOaWRXVnBJTnYzc00/view?usp=sharing

Is the driver expected to fail without legacy option rom?

BTW, when I boot with legacy option rom enabled, I see following warning in dmesg:

[    2.371552] NVRM: Your system is not currently configured to drive a VGA console
[    2.371554] NVRM: on the primary VGA device. The NVIDIA Linux graphics driver
[    2.371555] NVRM: requires the use of a text-mode VGA console. Use of other console
[    2.371556] NVRM: drivers including, but not limited to, vesafb, may result in
[    2.371556] NVRM: corruption and stability problems, and is not supported.

And there is no warning when legacy option rom is disabled. But for me the situation is exactly opposite: the driver is unstable without legacy option rom.

I’m having the exact same issue with my GTX 970 on Arch Linux using the latest drivers. There are 2 Dell displays attached to the card via DisplayPort, a U2412M and a P2416D.

Please see these related Debian [1] and Ubuntu [2] bug reports for further information

[1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=801146
[2] https://bugs.launchpad.net/ubuntu/+source/xorg/+bug/1493921

I am also affected by this issue on Alienware 17" laptop. It happens during regular boot-up no matter what i do (no control of display here). I had to roll drivers back to 361.45.18-3 from 367.44-3. If there’s any info which might help, tell me which logs do you need (those which i’ve checked look identical to OP logs).

I found this; note that the workaround was to roll back to an older driver: https://devtalk.nvidia.com/default/topic/935099/linux/-ee-nvidia-0-failed-to-enter-vt-mode-initialization-failed-with-quot-load-legacy-option-rom-qu/

I’m still affected by this bug on debian, which installs 375.82-4 from the repo.

This is easily single the most annoying bug with my system. But unfortunately, it’s not that easy to roll drivers back, and installing it manually on each kernel update is no-go.

So why is it painful?

On each system boot, X attempts to start and crashes, which results in screen ‘blinking’, it’s turned off, then turned on with black background, which repeats in endless cycle. I work around it by closing laptop lid, waiting until it goes into suspend, then opening lid, which resumes it. After 5 (on average) such cycles X is started up successfully.

After getting into my user session, if i want to stop working on laptop, i suspend it. On resume, chances to get it to operational state are higher: it gets into X properly with 33-50% chance. And, unlike after-bootup, after resume switching TTYs works: you can switch to 3rd and then back to 1st, and there’s decent chance that X will start up properly this time.

@DarkFenX
I don’t think you’re experiencing the same issue as the OP since that’s about a disabled option ROM.
Why not opening a new thread and providing the output file from nvidia-bug-report when the issue hits?

@generix

If i’m reading “disable legacy rom” option right, the issue might be applicable to me too, as my laptop is UEFI-based, quite possibly without the option to enable legacy mode is not there. I haven’t checked for almost a year, but a year ago i’m pretty sure I checked all the bios settings exposed via UI.

I found this thread after checking logs and searching for solutions using keywords from them, and found either this thread or debian bug (which are interconnected).

However, I’ll try to see if logs changed and will either update this thread with new info or post new one, if logs will be any different.