mhwd auto sets display driver to hybrid-video-intel-nvidia-440x-prime, however powertop shows card as always being on (MX250)

So I'm new to Manjaro, however I've managed to set optimus under Ubuntu-based systems so i know it's possible with my setup.

My laptop has Nvidia MX250 as its GPU, as well as an Intel GPU.
Manjaro's mhwd -a nonfree 0300 automatically installed the following driver: hybrid-video-intel-nvidia-440x-prime. After some investigation, I found out that this driver supports Nvidia's proprietary GPU offloading solution, as well as turning off the GPU when inactive. However, this feature is said to only work on Coffee Lake+ CPU's and Turing architecture GPU's.

While I do have a Coffee Lake CPU, my video card is one of the very last cards to still use Pascal architecture. Therefore, I concluded that the driver recommended by Manjaro does not disable the Nvidia GPU when not in use.

This is confirmed by my powertop output, i think (i'm new to powertop, i find it weird that everything shows up as 100%, however I have read that when the Nvidia GPU is not active, it should not show up at all in powertop):

Power est.    Usage     Device name
  12.3 W     44,2%        CPU misc
  635 mW     44,2%        CPU core
  374 mW     44,2%        DRAM
    0 mW     68,3%        Display backlight
            100,0%        USB device: xHCI Host Controller
            100,0%        USB device: ROG STRIX IMPACT (ASUS)
            100,0%        Radio device: iwlwifi
            100,0%        Radio device: btusb
            100,0%        PCI Device: Intel Corporation Cannon Point-LP SATA Controller [AHCI Mode]
            100,0%        PCI Device: NVIDIA Corporation GP108M [GeForce MX250]
            100,0%        PCI Device: Intel Corporation Xeon E3-1200 v5/E3-1500 v5/6th Gen Core Processor The
            100,0%        PCI Device: Intel Corporation Coffee Lake HOST and DRAM Controller
            100,0%        PCI Device: Intel Corporation Cannon Point-LP PCI Express Root Port #13
            100,0%        PCI Device: Intel Corporation Cannon Point-LP PCI Express Root Port #5
            100,0%        PCI Device: Intel Corporation Cannon Point-LP CNVi [Wireless-AC]
            100,0%        PCI Device: Sandisk Corp Device 5004
            100,0%        PCI Device: Intel Corporation UHD Graphics 620 (Whiskey Lake)
            100,0%        PCI Device: Intel Corporation Cannon Point-LP USB 3.1 xHCI Controller
            100,0%        PCI Device: Intel Corporation Cannon Point-LP Thermal Controller
              0,0%        PCI Device: Intel Corporation Cannon Point-LP SMBus Controller
              0,0%        PCI Device: Realtek Semiconductor Co., Ltd. RTL810xE PCI Express Fast Ethernet cont
              0,0 pkts/s  Network interface: wlo1 (iwlwifi)
              0,0 pkts/s  Network interface: enp3s0 (r8169)

Therefore, I figured the default configuration proposed by mhwd is not adqeuate for my setup, and started looking for alternative solutions.

First, I looked into optimus-manager, as that seems to be the most well supported option.
However, none of the power management configurations seemed to work.
Either I couldn't switch to the nvidia card at all, i'd get a blackscreen when switching, or it would switch, but it wouldn't power down the nvidia card when switching back to Intel. (I did not try the acpi one, however).
Question: Should I have uninstalled video-hybrid-intel-nvidia-440xx-prime and installed video-nvidia-440xx and xf86-video-intel when using optimus-manager? I did not find anything about this in the documentation, so I figured it would be best if i stuck with what mhwd recommended.

I then installed nvidia-switch and, while it did work (i did uninstall video-...-prime and installed nvidia-440xx and xf86-video-intel here, since it was specified as such in the documentation), I got a lot of graphical screen glitches when using intel mode (screen tearing, freezing when using full-screen applications) which were not fixed by archwiki's recommendations on screen tearing using xf86-video-intel. Additionally, the having to reboot aspect was not to my liking.

I'm now looking into nvidia-xrun, however it is not clear to me whether it would help me achieve my goal of having the nvidia videocard completely turned off when not in use. I'm doing all of this for battery saving purposes.

Do i need to remove hybrid-video-intel-nvidia-440xx-prime and install xf86-video-intel and video-nvidia-440xx when trying any other optimus management solution? I can't find much info anywhere.

Thanks!

Just to be sure, you followed this all the way?


If that doesn't work, maybe you are better with Optimus-Switch

1 Like

Yes, I followed it all the way.

Here are some results I got with experimenting:

power management options i tried (optimus manager):
1==========
switching method:none
pci reset:no
pci power control:yes
pci remove:no

result: switching works, have to log in 2-3 times until it decides to switch. NVIDIA card never powers off.
2==========
switching method:none
pci reset:no
pci power control:yes
pci remove:yes

result: Nvidia card is powered off. On switch, it refuses to power on. blackscreen.

3==========
switching method:bbswitch
pci reset:no

result:NVIDIA card never powers off. switching works, have to log in 2-3 times until it decides to switch.

4==========
switching method:nouveau
pci power control:yes

result:completely breaks everything, had to boot from live usb to fix session, not even the virtual tty's worked anymore.

Optimus Manager (Setup script) version 1.2.2
Setting up the GPU
Checking status of optimus-manager.service
Cleaning up leftover Xorg conf
Loading config
Requested mode : intel
Checking for GDM display servers
Available kernel modules : ['nouveau', 'bbswitch', 'nvidia', 'nvidia_drm', 'nvidia_modeset']
Setting up base state
Unloading modules ['nvidia_drm', 'nvidia_modeset', 'nvidia'] (if loaded)
Unloading modules ['nouveau'] (if loaded)
Cannot setup GPU : kernel setup error : Cannot unload modules ['nouveau'] : Failed to execute 'modprobe -r nouveau' : modprobe: FATAL: Module nouveau is in use.


5=========
switching:acpi
pci reset:no
pci remove:no
result: switching works. NVIDIA gpu never powers off. (as shown in powertop)

6========
switching:acpi
pci reset:no
pci remove:yes
result: nvidia card disabled on intel boot. on switch, nothing loads. blackscreen.

7=======
switching:acpi
pci reset:function level
pci remove:yes
result:nvidia card disabled on intel boot. on switch, nothing loads. blackscreen.

8=======
switching:acpi
pci reset:function level
pci remove:no
result: switching works. NVIDIA gpu never powers off. (as shown in powertop)

At this point, I'm considering using one of the configurations where only Intel loads for when i need power saving, and switching to one where NVIDIA works all the time when i need it.

Does optimus-switch work with video-hybrid-intel-nvidia-440xx-prime ? If yes, i'll try it out too. Trying it using xf86-video-intel had me deal with screen tearing issues which I couldn't fix.

I honestly don't know. I would rely on what the how to describes what to do and i would go with it. :slight_smile:

I have a laptop with MX250 + Intel graphics and optimus-switch works flawlessly for me. Really recommend it. When you enable Intel mode, Nvidia card stays off, and when you enable Nvidia mode, it works like Nvidia Prime.

Guide is really easy to follow.

I see you are using manjaro gnome: https://github.com/dglt1/optimus-switch-gdm

I'm sure you wanted to address that to the OP, not me :slight_smile:

Yeah lol, sorry for that.

Hi! Did you use any custom configuration for the Intel card, in order not to get screen tearing?
I also had decent success with optimus-switch, apart from this annoying inconvenience. I'll look into it again today and report back with the results.

I get this error when installing acpi_call-dkms: "Unable to install module acpi_call/1.1.0 for kernel 3.16.82-3-MANJARO: Missing kernel headers."
Therefore I went with the acpi_call for my kernel version(5.4)
Sadly, optimus-switch does not seem to turn off my nvidia card either. Powertop output, in intel mode:

owerTOP v2.11    Overview   Idle stats   Frequency stats   Device stats   Tuna
    0 mW    100,0%        USB device: ROG STRIX IMPACT (ASUS)
    0 mW    100,0%        USB device: xHCI Host Controller
    0 mW      0,0%        Audio codec hwC0D0: Realtek
    0 mW      0,0%        USB device: Integrated_Webcam_HD (CN0HK46K8LG0095EA7X
    0 mW      0,0%        USB device: usb-device-8087-0aaa
            100,0%        PCI Device: Intel Corporation UHD Graphics 620 (Whisk
            100,0%        PCI Device: Intel Corporation Cannon Point-LP SATA Co
            100,0%        PCI Device: Intel Corporation Cannon Point-LP CNVi [W
            100,0%        PCI Device: Intel Corporation Cannon Point-LP USB 3.1
            100,0%        PCI Device: Sandisk Corp Device 5004
            100,0%        PCI Device: Intel Corporation Xeon E3-1200 v5/E3-1500
            100,0%        PCI Device: NVIDIA Corporation GP108M [GeForce MX250]
            100,0%        PCI Device: Intel Corporation Cannon Point-LP PCI Exp
            100,0%        PCI Device: Intel Corporation Cannon Point-LP Thermal
            100,0%        PCI Device: Intel Corporation Coffee Lake HOST and DR
            100,0%        PCI Device: Intel Corporation Cannon Point-LP PCI Exp
             17,4%        PCI Device: Intel Corporation Cannon Point-LP Serial
             17,3%        runtime-i2c_designware.0

What am I doing wrong? It has to be related with that acpi_call-dkms package.

Edit: Nevermind, figured it out! Leaving this here for future searchers.

  1. install linux316-headers then reinstall acpi_call-dkms
  2. sudo modprobe acpi_call
  3. check if the Nvidia card Bus ID is set correctly everywhere in /etc/switch/intel/no-optimus.sh - I must have messed something up during my installation, as it did not change in the config. (i also seem to have a really weird setup: nvidia card is 02:00.0, intel is 00:02.0)

Now all I have to do is figure out the screen tearing problem.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

Forum kindly sponsored by