You are not logged in.

#1 2021-07-22 01:28:09

soneminu
Member
Registered: 2021-07-22
Posts: 6

[Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

Laptop model:
HP Omen 15-ax200

Specs:
Processor: Intel Core i7-7700HQ
GPU: Nvidia GeForce GTX 1050 Ti 4GB
Proprietary driver version: 470.57.02

The problem:

OverrideMaxPerf kernel module option, as well as other options, seems to have no effect.

Desired outcome:

The graphics card will stay locked to the performance level specified in the kernel module option.

Procedure:

I installed the latest proprietary drivers from the official repositories;

# pacman -S nvidia nvidia-settings
$ reboot

Then, I edited /etc/default/grub and added;

nvidia-drm.modeset=1

And added these modules to /etc/mkinitcpio.conf;

MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)

After which I regenerated the initramfs with;

# mkinitcpio -P

The objective is to lock the dedicated graphics card to a desired performance level by executing;

# modprobe nvidia Nvreg_RegistryDWords="OverrideMaxPerf=XYZ"

And creating  the /etc/modprobe.d/nvidia.conf kernel module option file, containing;

options nvidia Nvreg_RegistryDWords="OverrideMaxPerf=XYZ"

Where XYZ is the desired performance level. My graphics card has four performance levels available: 0x0, 0x1, 0x2, and 0x3, with 0x0 being the lowest power level to my (limited) knowledge. After creating the kernel module option file, I regenerated the initramfs once again, and rebooted the computer.

To test whether the performance mode would stay locked, I ran a Windows game through Lutris, with Wine version lutris-fshack-6.10-7-x86_64, and used mangohud to measure the CPU temperature, GPU temperature, and GPU clock speed. I also had the nvidia-settings window open. Before running the game, I ran;

# modprobe nvidia Nvreg_RegistryDWords="OverrideMaxPerf=0x0"

To lock the performance level to the lowest performance level, which  would effectively limit my GPU's clock to a maximum of 607 MHz. What I noticed is that, instead, the clock read 1721 MHz. I also tried running the command and setting different performance levels (0x1, 0x2, and 0x3), which seemed to make no difference. The clock was still reading 1721 MHz.

I set OverrideMaxPerf=0x0 in the kernel module option file, regenerated the initramfs yet again, and rebooted the system. The clock was still reading 1721 MHz.

What I haven't tried yet is downgrading the drivers, but that'll be the last option.

I'm still fairly new to Arch Linux, so I do apologize in advance. Please point me in the right direction to solve this problem.

Extra notes:

The command;

$ nvidia-smi -lgc

Does not work; it returns;

Setting locked GPU clocks is not supported for GPU 00000000:01:00.0.
Treating as warning and moving on.
All done.

Which is a bit bizarre, since it is possible in Windows in this hardware.

Last edited by soneminu (2021-07-23 22:42:19)

Offline

#2 2021-07-22 03:48:55

ewaller
Administrator
From: Pasadena, CA
Registered: 2009-07-13
Posts: 17,845

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

I saw the report.  Did you wish me to delete the thread? I see you edited the original post.  I will delete post #2


Nothing is too wonderful to be true, if it be consistent with the laws of nature -- Michael Faraday
Sometimes it is the people no one can imagine anything of who do the things no one can imagine. -- Alan Turing
---
How to Ask Questions the Smart Way

Offline

#3 2021-07-22 06:10:16

seth
Member
Registered: 2012-09-03
Posts: 22,153

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

Offline

#4 2021-07-22 07:30:05

soneminu
Member
Registered: 2021-07-22
Posts: 6

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

Hello and thank you for replying. I did look there first.

That thread's OP's kernel modules and options were joined by a period rather than being separated by a space;

nvidia.NVreg_RegistryDwords="OverrideMaxPerf=1"

I wasn't sure this was correct. I figured if I couldn't execute;

# modprobe nvidia.NVreg_RegistryDwords="OverrideMaxPerf=0x1"

In a bash terminal because the kernel module and its option need to be separated by a space, then adding it verbatim to /etc/modprobe.d/nvidia.conf wouldn't work either, but it was worth a shot. It didn't work. I also tried adding the DynamicPowerManagement option, but that didn't work either. Note that after every change/addition I'd regenerate the initramfs, just to make sure (I don't even know if it was at all necessary other than after adding the modules to /etc/mkinitcpio.conf.

The OP in that thread downgraded their driver version to make the kernel module options work. It's the last thing I wanted to do, hoping that there would be another solution, which led to me opening this thread. But if that's the only solution then I'll go ahead.

I'm not even sure if it'll work since my hardware is different from that thread's OP, also considering that the OP disabled their Intel card in BIOS. I can't do that. I'm on a laptop. I'll come back with an update.

Last edited by soneminu (2021-07-22 07:32:18)

Offline

#5 2021-07-22 07:34:13

seth
Member
Registered: 2012-09-03
Posts: 22,153

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

The nvidia.whatever syntax is correct in the context of the kernel commandline (rather than a modprobe configlet or the modprobe command)

Offline

#6 2021-07-23 09:05:39

soneminu
Member
Registered: 2021-07-22
Posts: 6

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

Update: It didn't work, unfortunately. I downgraded to driver version 460.67, same version as the previously linked thread's OP, and then down to 455.45.01. Every time I downgraded, I went through the same steps; setting up modules, modprobe conf files... nothing worked.
I also tried adding the module with the nvidia.<options> syntax to /proc/cmdline as described here https://wiki.archlinux.org/title/Kernel … ng_cmdline and ran;

# cat /proc/cmdline

To confirm that the module was indeed there, and rebooted the laptop. No dice.

I attempted one last thing. In a clean install with no drivers, I installed linux-headers, and nvidia-dkms-performance from the AUR. In the PKGBUILD, I edited;

_override_max_perf=1

Then I built the package, and rebooted, hoping the card would stay at the lowest power level, with the idea of using optimus-manager, switching to nvidia, and applying a clock offset in nvidia-settings when needed (for this, overclocking would have to be enabled in optimus-manager's config).

Even so much as moving a window around in my DE would make the card jump immediately to performance level 3 (1700+MHz), when it was supposed to stay at the lowest level. Tried different DEs as well to see if maybe that was the issue (unlikely).

Unfortunately, nothing works.

With little to no information or solutions available in the internet for this problem, I've concluded that what I'm trying to achieve simply is not possible in Linux-based operating systems, at least not with my current hardware. The nouveau drivers are not an option either; they support reclocking, but only on certain cards, and not the NV130 family to which my card belongs.

I'll switch back to Windows. The ability to fine tune my card's performance far outweighs any other benefit of using Arch Linux for my use case, which is unfortunate because I really like Arch Linux.

Thank you for your assistance.

Offline

#7 2021-07-23 14:13:41

seth
Member
Registered: 2012-09-03
Posts: 22,153

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

idea of using optimus-manager

optimus-manager un/loads the nvidia module itself, you'd check "systool -vm nvidia"

One more thing: the full composition mode will trigger the performance mode and occur w/
a) multiscreen setups
b) scaled outputs

Even so much as moving a window around in my DE would make the card jump immediately to performance level 3 (1700+MHz)

Though this sounds like it might be due to an OpenGL compositor. Did you try eg. openbox (w/o picom etc.)?

Offline

#8 2021-07-23 20:17:20

soneminu
Member
Registered: 2021-07-22
Posts: 6

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

seth wrote:

idea of using optimus-manager

optimus-manager un/loads the nvidia module itself, you'd check "systool -vm nvidia"

One more thing: the full composition mode will trigger the performance mode and occur w/
a) multiscreen setups
b) scaled outputs

Even so much as moving a window around in my DE would make the card jump immediately to performance level 3 (1700+MHz)

Though this sounds like it might be due to an OpenGL compositor. Did you try eg. openbox (w/o picom etc.)?

Hello and thank you for getting back to me.

Yes, I apologize for not having mentioned this, but compositing was indeed disabled this entire time. I don't even have a second monitor either. I tried MATE, xfce4, plasma, cinnamon, you know the more common ones.

I'd already installed Windows again at this point, but decided I'd give this one more shot.

I tried one last time with openbox like you suggested, since I had never heard of it. I couldn't get any of the dynamic menus or generators to work, so I had to manually add entries to the static menu. I went once again through the whole procedure and, well, it didn't work.

I'm just too tired at this point to continue trying. I really do appreciate your help but I'll stick to Windows.

How do I close the thread?

Last edited by soneminu (2021-07-23 20:20:59)

Offline

#9 2021-07-23 20:30:43

seth
Member
Registered: 2012-09-03
Posts: 22,153

Re: [Abandoned] OverrideMaxPerf kernel module option not locking GPU clock

https://archlinux.org/packages/community/any/menumaker/ - though you'd not need that for a function test.

You can either edit your original post and alter the subject to include sth. like "[abandoned]" (don't use "closed", it's what mods do to locked threads) or report it for deletion.

Offline

Board footer

Powered by FluxBB