LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   NVidia Legacy 390.138 and Kernel 5.10.x (https://www.linuxquestions.org/questions/slackware-14/nvidia-legacy-390-138-and-kernel-5-10-x-4175687158/)

willysr 12-19-2020 10:35 PM

NVidia Legacy 390.138 and Kernel 5.10.x
 
I have added patches to build NVidia Legacy Driver (390.138) to work with Linux Kernel 5.10.x on my SlackHacks repository just in case anyone need it.

Credit goes to Herecura

chrisretusn 12-20-2020 12:35 AM

Quote:

Originally Posted by willysr (Post 6197592)
I have added patches to build NVidia Legacy Driver (390.138) to work with Linux Kernel 5.10.x on my SlackHacks repository just in case anyone need it.

Credit goes to Herecura

Thanks you very much for that. I'm not currently using 5.10.x but had anticipated that we might be getting it in -current in the near future. ....

Yikes! Just checked ChangeLog.txt. It is here!

Not to give that patch a try. Again many thanks!! :hattip:

chrisretusn 12-20-2020 07:17 AM

Successfully running with Linux Kernel 5.10.1 with the patches applied to the NVIDIA Legacy Driver (390.138).

I tried the install without the --no-unified-memory parameter first. I don't have CUDA installed. The install completed successfully. So I'll stick with that.

willysr 12-20-2020 09:46 AM

oh really? it failed here so i added that in the README

chrisretusn 12-21-2020 07:24 AM

I have a GeForce GT 730 Device ID: 0x0f02

chrisretusn 12-22-2020 06:14 AM

Well, go figure. :scratch:

Today I upgraded to 5.10.2, then rebuilt the NVIDIA drivers, this time the "--no-unified-memory" option was required.

This is the exact command line I used on my first upgrade with 5.10.1 from the extracted directory.
Code:

# ./nvidia-installer -k 5.10.1
This was from the currently running 5.4.84 kernel, this could be why it worked. :scratch:

I used the same today except with 5.10.2, now it wants the "--no-unified-memory" option.

I :doh: forgot to rebuild the NVIDIA kernel for 5.10.2, I was reminded of my forgetfulness after I issued 'startx', silly me. Been awhile since I was silly like that. All is of course well now after running.
Code:

# ./nvidia-installer -K --no-unified-memory

willysr 12-22-2020 06:25 AM

once you patched the source, you don't need to rebuild the NVidia kernel again, just run nvidia-installer <option>

claudecat 12-22-2020 02:12 PM

Forgive my ignorance, but I'm having trouble patching the 390 driver following the instructions provided. I am somewhat unclear as to the exact process...

First off, I've got the NVIDIA-Linux-x86_64-390.138.run file, while the instructions reference the NVIDIA-Linux-x86-390.138.run file. Is this correct? Should I be using the x86 file on a non-multilib system?

Secondly, should I apply all the patches referenced in the instructions (i.e. kernel-4.16.patch through to the kernel-5.10.patch), in the order given? Or just the kernel-5.10.patch?

In my attempt to apply the patches in order, the kernel-5.10.patch results in this:

Code:

patching file kernel/common/inc/nv-linux.h
Reversed (or previously applied) patch detected!  Assume -R? [n]

I've tried a few variations of the above, each time resulting in failure to build the module. I have used the --no-unified-memory switch each time I've tried. Any help would be appreciated! Nouveau works but has some screen flickering here and there. My card is a GeForce GT430 if that helps.

willysr 12-22-2020 07:01 PM

My bad. It was previously made for x86, but now i update it for x86_64
You need to patch everything according to the README. If you try to patch only using the 5.10 patch, you will get that error (i stumbled on that one too on my first attempt).

claudecat 12-22-2020 07:52 PM

Thanks! After applying all patches to the extracted .run file, as per your instructions, everything's working now. Turns out I had copied the wrong patch into the kernel-5.10.patch file, so I was even dumber than I thought...

So great to have Plasma 5 and the 5.10 kernel in -current. Big thanks to Pat, Eric, and all you fine folks here that keep this unique and historic distro moving forward. I'm sure I'm not the only lurker (mostly) that benefits from y'all's vast knowledge and effort.

Lenard Spencer 12-23-2020 11:15 AM

Quote:

Originally Posted by willysr (Post 6197592)
I have added patches to build NVidia Legacy Driver (390.138) to work with Linux Kernel 5.10.x on my SlackHacks repository just in case anyone need it.

Credit goes to Herecura

VERY MUCH thanks for the patches. Just tested with my SBo script in both 14.2 and current, and so far works beautifully. I will be sending the new script to SBo shortly.

UPDATE: Had to make a couple of minor edits for 32-bit. The 32-bit nvidia kernel source does not have the nvidia-uvm folder, so the kernel-5.9.patch is now two different patches, one for x86, one for x86_64. The kernel-5.8-license-bypass.patch is not used on 32-bit for the same reason (no nvidia-uvm folder).

willysr 12-23-2020 12:56 PM

yeah probably because they didn't test it for x86 anymore. Most distros are abandoning 32 bit architecture

ReFracture 12-23-2020 02:10 PM

Every time the kernel does a big update like this I expect the 560m in my Asus G74SX to be relegated to nouveau.. but yet again, not this time.

Thanks.

however 12-23-2020 02:53 PM

sorry, it didn't work for me on my laptop as you suggested here
I am getting so frustrated and I cant believe that in 2021 bcos of a kernel update i have to unplug my second monitor

chrisretusn 12-24-2020 06:01 AM

Quote:

Originally Posted by willysr (Post 6198516)
once you patched the source, you don't need to rebuild the NVidia kernel again, just run nvidia-installer <option>

Ah, that is what nvidia-installer does, builds the NVIDIA kernel modules and installs the NVIDIA files.

I agree that once the source is patched, source being the extracted NVIDIA-Linux-x86-390.138 directory. Then you can run the nvidia-installer but it must be run from within that extracted and patched directory otherwise the nvidia-installer will give you a "No package found for installation." error.

Without any options the nvidia-installer will build for the running Linux kernel and install the NIVIDIA files. The -k option tells the installer to use a different Linux kernel than the running Linux kernel. Useful if you have more than one kernel installed or you want to install before rebooting. I normally have two kernels installed. If only the Linux Kernel was upgraded (not mesa or xorg-server) then you can use the -K options to tell the installer to just build the NVIDIA kernel modules.


All times are GMT -5. The time now is 11:16 AM.