Reverse-Engineered NVIDIA Driver Works On Re-Clocking

Written by Michael Larabel in Nouveau on 24 January 2012 at 01:27 PM EST. 1 Comment
NOUVEAU
While Nouveau for open-source NVIDIA support in Mesa 8.0 is mixed, the developers behind this reverse-engineered NVIDIA driver are making some progress and hope to have more positive information to report soon.

In response last week to publishing the aforelinked benchmarks comparing the latest Nouveau code (for the Linux kernel and its Nouveau DRM and the Mesa 8.0 user-space) compared to the official but binary-only NVIDIA driver, Martin Peres (also known by his "MùPùF" Internet handle) shared a few notes within the Phoronix Forums.

In his first message he shared that by the time of FOSDEM (next weekend) "we should have our reclocking code for geforce 8/9 merged with timing management by then. Nva3-c0 is also on the way but will require a little more time."

The re-clocking code is what will allow these select generations of NVIDIA hardware to run at their optimal core, shader, and memory clocks. Right now the Nouveau driver support for this has been hit-or-miss depending upon the graphics card. For newer generations of hardware, Nouveau is running at whatever it's started at, but hasn't been able to boost itself to the optimal graphics clock speeds when needed for handling OpenGL and other workloads. This has been a big problem for especially the GeForce 400/500 "Fermi" hardware as by default the clock speeds can be disappointing, which leads to a frustratingly slow experience with Nouveau.

It's been possible to first load the NVIDIA binary driver so you can run up the graphics card to its highest clock states, then softly restart with kexec, and load the Nouveau driver instead. However, that's not as simple as just setting a xorg.conf option or other easy configuration option as would be recommended for end-users looking for a pleasant "out of the box" experience. First needing to load and run the NVIDIA binary driver also defeats the purpose of using the open-source Nouveau stack.

At least soon this will change for the higher-end GeForce 8/9 graphics cards under Nouveau and eventually for the newer generations of NVIDIA hardware. (For some low and mid-range pre-Fermi graphics cards, they had a minimal number of power levels, so there it's less of a problem if the default state is the highest.)

About the dynamic re-clocking for Nouveau, Martin Peres wrote, "Finally found a working solution for fully stable reclocking about 2 weeks ago. It is on its way to be merged into the nouveau tree and will be part of Linux 3.4 along with memory timing management on geforce 8/9 and maybe on geforce 200/300 too." The memory timing management in Nouveau is largely the work of Roy Spilet and Ben Skeggs at Red Hat is who's been working on the clock tree support and other work.

Additionally, Martin shared within our forums that Mesa 8.0 has been minimally tested under Nouveau -- even by their own developers. "the work towards mesa 8 in Nouveau is really recent and haven't been thouroughtly tested on all cards we have, even by Nouveau devs. If any enthusiast user was to test it when the beta comes out and some bugs are still present, please show up on IRC and report it." (They're #nouveau on freenode.net for those interested in doing so.)

Assuming the re-clocking support is working as expected, the Linux 3.4 kernel should be quite interesting. However, with not even being up to Linux 3.3-rc2 yet, it will be a ways out before any casual Linux desktop users are seeing good things out of their Nouveau stack. I.e. Ubuntu 12.10 will hopefully play well and perform much better for open-source on NVIDIA graphics cards. Let's just hope by H2'2012 that Fermi re-clocking is figured out and that they'll be able to start supporting the soon-to-be-released GeForce 600 "Kepler" series.

In related Nouveau news, floating on the mailing list have been some experimental patches to reduce the Nouveau driver power usage. For at least an NV86 board it makes the Nouveau driver power usage more in line with the NVIDIA binary blob. However, the patches in the current form are not meant for merging.

The power-reducing patches by Maxim Levitsky enable PCI Express power savings and PGRAPH's clock gating support for NV50, support for powering down the VDEC when re-clocking, and powering down unused DACs. Another patch by Levitsky has some "power usage magic" that drops the GPU power consumption slightly by setting some unknown bits within the memory controller. For those wanting to know how the Nouveau power consumption currently compares to NVIDIA's proprietary driver, see the 14-way graphics card comparison.

The next round of Nouveau benchmarks will be on Phoronix as soon as tomorrow when testing out a $10 USD graphics card from NVIDIA.

Martin Peres will be talking about the state of Nouveau and its future next week at FOSDEM in Brussels. I'll be there covering it live on Phoronix.
Related News
About The Author
Michael Larabel

Michael Larabel is the principal author of Phoronix.com and founded the site in 2004 with a focus on enriching the Linux hardware experience. Michael has written more than 20,000 articles covering the state of Linux hardware support, Linux performance, graphics drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated benchmarking software. He can be followed via Twitter, LinkedIn, or contacted via MichaelLarabel.com.

Popular News This Week