Black screen NVIDIA Driver 415.23 on linux-4.20-rc*

Greetings and best wishes to all. I’m hoping that I might get some much needed assistance in resolving
this problem.

I’ve not had this kind of problem previously with the binary drivers, vamilla kernels and my GeForce
GT 640. In fact, 415.23 runs splendidly on previous kernels until it tangles with anything 4.20*. I’ve added ‘Option “ModeDebug” “true”’ to the ‘Screen’ section of my xorg.conf and am trying to work out how
to add the subsequently generated nvidia-bug-report.log.gz.

Please advise and many thanks in advance.

NB: I had also retrieved the following information from journalctl which may very well be useful:
command run:
journalctl --since “2018-12-17 00:00:00” --until “2018-12-17 20:00:00” -l --no-pager |grep -i nvidia |egrep -i ‘warning|error’ |less

OUTPUT:
Dec 17 05:17:18 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 05:21:52 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 05:35:57 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 05:43:38 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 05:52:44 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 06:03:13 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 13:42:06 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 14:00:03 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
Dec 17 14:18:07 turbo2 kernel: nvidia-modeset: WARNING: GPU:0: Lost display notification (0:0x00000000); continuing.
nvidia-bug-report.log.gz (1.03 MB)

Result! My hopes being dashed again after installing the latest 415.25 driver, and without seeing my desktop rising into the light of day, I had another look through my /var/log/Xorg.0.log.old.

There I found the clue which I needed:
kernel: NVRM: API mismatch: the client has the version 415.25, but
NVRM: this kernel module has the version 415.23. Please
NVRM: make sure that this kernel module and all NVIDIA driver
NVRM: components have the same version.

Haa…le…lu…yah!!

This looks like the latest in an ongoing series of mismatches (or something like that).

Solution:
dkms install -m nvidia -v 415.25 -k 4.20.0-rc7
reboot into kernel-4.20.0-rc7

Correction, it was not in /var/log/Xorg.0.log.old that I found the above error message.

The error message in /var/log/Xorg.0.log.old was:
(EE) NVIDIA(0): Failed to initialize the NVIDIA kernel module!

I then googled the error message and found https://us.download.nvidia.com/XFree86/FreeBSD-x86/275.09.07/README/commonproblems.html which informed:

Nothing will work if the NVIDIA kernel module does not function properly. If you see anything in the X
log file like

    (EE) NVIDIA(0): Failed to initialize the NVIDIA kernel module!

then there is most likely a problem with the NVIDIA kernel module.

The NVIDIA kernel module may print error messages indicating a problem – to view these messages check
the output of dmesg, /var/log/messages, or wherever syslog is directed to place kernel messages. These
messages are prepended with “NVRM”.

I then ran the following command:
journalctl --since “2018-12-19 15:00:00” --until “2018-12-19 16:00:00” -l --no-pager |egrep -i ‘NVRM’ |less

which returned
Dec 19 15:05:17 kernel: NVRM: API mismatch: the client has the version 415.25, but
NVRM: this kernel module has the version 415.23. Please
NVRM: make sure that this kernel module and all NVIDIA driver
NVRM: components have the same version.

I then implemented the solution documented in my previous post.