Guide to (Nvidia) monitor overclocking on Linux
|
11-14-2014, 02:01 PM
(Last edited: 11-14-2014, 06:17 PM by kablammo)
Post: #1
|
|||
|
|||
Guide to (Nvidia) monitor overclocking on Linux
Hey there,
Since I was a bit bored, I looked into overclocking my Monitors with the Proprietary Linux drivers on Linux. First things first For pretty much all of the config file modifying you need to be root (you can get root rights with sudo or by logging into root with su) . It's good to have full debugging output for X.org, it tells you a lot and you can easily see if you made an error. To do so, start X with -logverbose 6. This can be done by editing you desktop managers config file. for KDM it's /etc/kde4/kdm/kdmrc where you add it to ServerArgsLocal=. For lightdm (ubuntu default) you can find this at /etc/lightdm/lightdm.conf where under [SeatDefaults] you need to add xserver-command=X -logverbose 6. Restart your computer (or only your DM). Now if something does not work, you can check /var/log/Xorg.0.log, it will give you a very detailed output of what happens. After all is done and works the way you want it , you can disable all the extra logging. Tell the Nvidia driver to ignore every precaution Go to your /etc/X11/xorg.conf (it it's not yet generated, you can create it with the nvidia gui) and add Option "ModeValidation" "AllowNonEdidModes,NoEdidMaxPClkCheck,NoMaxPClkCheck" to Code: Section "Screen" Code: Section "Device" and finally modify your VertRefresh to fit your needs Code: Section "Monitor" Now you told the nvidia driver to ignore any refresh rates that the monitor tells it and to ignore Bandwidths too. For more info about all these settings look here: http://ftp.download.nvidia.com/XFree86/L...tions.html I am not certain how far NoMaxPClkCheck goes, if it can get past the 330 Mhz Pixel Fequency. I can't test it since I got ancient Screens and only did this to have a bit of fun. But fear not, there is a patch for the nvidia driver. You get it here : https://github.com/CFSworks/nvlinpatch download it, unpack, grab your nvidia kernel module from /lib/modules/<your kernel> put it where you unpacked nvlinpatch and run python2 nvlinpatch.py <name of the kernel module>. Then copy it back. If you use ubuntu, the Kernel module will be in /lib/modules/<kernel>/updates/dkms/nvidia_331.ko. Keep a backup of the original module just in case. Unfortunately because the kernel module gets built after every kernel update, you need to keep patching it. Now reboot your computer and you should already see a bunch more modes for you to choose from. Maybe already the one you want. Fine grained Modesetting Now that we have everything unlocked, you can start messing around with modelines if you want very precise control over your refresh rate. There are several ways to generate modelines. an easy one is to use cvt. it will spit out a line like Code: $ cvt 1920 1080 120 the first number after Modeline "1920x1080_120.00" is the Pixel Frequency, then the horizontal screen size then the 3 sizes needed to sync the screen lines. After that the vertical screen size and again 3 sizes to sync the screen. Now to test if your screen works with this, run as normal user xrandr -q to find your screen name and then copy the modeline and use it with xrandr like so: Code: xrandr --newmode "1920x1080_120.00" 369.50 1920 2080 2288 2656 1080 1083 1088 1160 -hsync +vsync if everything works great for you, you can copy the output from cvt to /etc/X11/xorg.conf Code: Section "Monitor" and the next time you reboot, you'll find it in your nvidia settings. Now if you happen to only have crummy cables and be really tight on bandwidth, you can check your monitors current modeline with Code: xvidtune -show You can also grab Modlines from your edid by reading your Xorg.0.log, it needs logverbose 6 , but it seems to be the most reliable way to get information from your edid. Code: [ 672.112] (--) NVIDIA(0): Detailed Timings: To use this as a start for your Modeline: Code: Modeline "<name>" <Pixel Clock> <HRes> <HSyncStart> <HSyncEnd> <HTotal> <VRes> <VSyncStart> <VSyncEnd> <VTotal> <H Polarity>hsync <V Polarity>vsync My screen for example has much smaller numbers for the synching parameters than the autogenerated line and thus needs less bandwidth per screen draw. You can take that line and slowly increase the Pixel Frequency ( in this case 154.00 ) and watch how your Screen reacts. Increasing the Frequency will increase your Vertical refresh rate, as the bandwith is the multiplication of the 2 largest numbers (HTotal and VTotal) on each group with the vertical refresh rate. X is a bit picky about how you name your modelines, the easiest is just to increase the number at the end 1920x1080_120.00 1920x1080_120.01 .... And again once you found a modeline you like, just copy it over to your xorg.conf and be done. And that's it. Sadly there are not many pretty guis to click stuff, but everything you need is pretty easy to get. Addendum I am not sure if the Patch is still actively maintained, however it seems that it only consists of replacing a few small numbers Code: uncap_pclk_dvi_64 = Patch('uncap_pclk_dvi_64', For drivers after 334, the display port patch is not applied anymore. I don't know if later nvidia drivers have changed a lot or if you could just reuse the same patches, After all it seems they have not changed since 310 edit: how to get a modeline from edid |
|||
07-07-2015, 03:31 PM
Post: #2
|
|||
|
|||
RE: Guide to (Nvidia) monitor overclocking on Linux
Thanks for this guide. I can't seem to get past 2560x1440 @ 80Hz in Linux, but I can get to 105Hz in Windows. Must be the pixel clock limitation you mentioned. I need to look into that.
|
|||
02-15-2018, 04:18 PM
Post: #3
|
|||
|
|||
RE: Guide to (Nvidia) monitor overclocking on Linux
I registered on the forum just to thank you, kablammo. The tutorial worked perfectly for me. I use Ubuntu 18.04 + GTX 1080 + Dell P2416D. Its default refresh rate is 60Hz, but it works perfectly with 75Hz.
Thanks to your tutorial I managed to make it work at 75Hz on linux. |
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)