You are not logged in.

#126 2019-03-19 18:30:01

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Morv wrote:
LazyLucretia wrote:

I had to make a small change though: at the end of the enableGpu script, I had to add "modprobe nvidia" since nvidia module did not get loaded by itself.

I will update OP accordingly. Thanks for all your work.

You shouldn't have to as Bumblebee loads the nvidia module when you start an application via optirun or primusrun and it unloads it once the application has exited(though not successfully all the time). Once the nvidia module is loaded the GPU drains your battery, that's the whole problem. Doesn't matter much when you're on AC but it affects your battery life noticeably.

If I enable it when I'm going to use it and disable it when I'm done, it's not going to consume more battery than it normally whould.

When I do not use `modprobe nvidia`, I get this infamous error:

[  197.958789] [ERROR]Cannot access secondary GPU - error: Could not load GPU driver

[  197.958806] [ERROR]Aborting because fallback start is disabled.

Offline

#127 2019-03-19 19:09:23

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Well, here goes my dreams of finally being able to use optirun... After running unigine-valley for a while, I cannot unload nvidia because ipmi_msghandler somehow got loaded eventhough it was blocked in /etc/modprobe.d/disable-ipmi.conf . Back to nvidia-xrun I guess.

Offline

#128 2019-03-21 09:10:05

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

mreichardt wrote:
Graff wrote:

After few days of experimenting and testing suggestions from this thread I was able to get switchable graphics to work on my XPS (1.5.0 bios, 4.20 kernel and nvidia 415.25). In my case, the main issue was automatic loading of nvidia modules on boot, immediately after decrypting my drive. Blacklisting by 'blacklist' option in /etc/modprobe.d/blacklist.conf didn't work. Additionally together with nvidia modules ipmi_msghandler and ipmi_devintf were loaded and they prevented unloading of nvidia. I had to use "install module_name /bin/false" command to successfully block loading of these three modules.

However, this metod also disabled loading of modules manually, by using "modprobe -a" command. Renaming / removing this file removes this obstacle, therefore in my scripts I append / remove .disable extension from conf file which holds install directive for nvidia module.

In this configuration my power consumption is ~4W on iGPU. After enabling dGPU and loading nvidia drivers it jumps to 6-7W. After disabling GPU it goes back to ~4W.

Bellow I attached my guide (as I usually prefer to write myself some instructions, as I will not remember details when I will have to do this again). I would be grateful if somebody would be able to reproduce my results by using this configuration (as I may already forgot some details). It is written in markdown.

This worked like a charm on my Dell Precision 5530 with Quadro P2000 Card! Had the issue that nvidia modules were loaded on boot by gnome. Your scripts solved that perfectly. Although one strange thing that happens to me. After enabling the GPU I'm unable to use it until i run nvidia-smi.

Something I noticed: nvidia-smi loads nvidia module, this is actually same issue that I'm experiencing. There is no practical difference between running `nvidia-smi` or `modprobe nvidia` after running enableGpu.sh.

Offline

#129 2019-03-21 11:25:33

Morv
Member
Registered: 2016-10-09
Posts: 14

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

LazyLucretia wrote:

Well, here goes my dreams of finally being able to use optirun... After running unigine-valley for a while, I cannot unload nvidia because ipmi_msghandler somehow got loaded eventhough it was blocked in /etc/modprobe.d/disable-ipmi.conf . Back to nvidia-xrun I guess.

No worries, you just stumbled into a problem with bumblebee, at least I guess that's it, which causes the program you launched with bumblebee to not get terminated. This causes the nvidia driver to stay loaded.

...
Loading "core/materials/default/unigine_volume.mat" 6 materials 53 shaders 2ms
Loading "core/materials/default/unigine_gui.mat" 1 material 82 shaders 0ms
Loading "core/materials/default/unigine_water.mat" 1 material 533 shaders 15ms
Loading "core/materials/default/unigine_sky.mat" 1 material 21 shaders 10ms
Loading "core/materials/default/unigine_decal.mat" 1 material 99 shaders 1ms
Loading "core/properties/unigine.prop" 2 properties 0ms
Unigine Valley Benchmark 1.0 (1.0)Unigine~# world_load valley/valley
Loading "valley/valley.cpp" 123ms
Loading "valley/valley.mat" 72 materials 964ms
Loading "valley/sound/sound.prop" 142 properties 1ms
Loading "valley/valley.world" 3212ms
Unigine~# quit
Close "libopenal.so.1"
Close "libGL.so.1"
[mv@gaunt ~]$ lsmod | grep nvidia
nvidia_modeset       1089536  2
nvidia              17633280  218 nvidia_modeset
ipmi_msghandler        65536  2 ipmi_devintf,nvidia
[mv@gaunt ~]$ 

Searching for the valley executable shows:

[mv@gaunt ~]$ ps aux | grep valley
mv       19129  8.5  3.7 1323936 606732 ?      Sl   12:15   0:23 ./valley_x64 -project_name Valley -data_path ../ -engine_config ../data/valley_1.0.cfg -system_script valley/unigine.cpp -sound_app openal -video_app opengl -video_multisample 0 -video_fullscreen 0 -video_mode 3 -extern_define ,RELEASE,LANGUAGE_EN,QUALITY_HIGH -extern_plugin ,GPUMonitor

After killing valley_x64, terminating won't help, you can then use the script again to unload the driver and disable the nvidia card.

[mv@gaunt ~]$ lsmod | grep nvidia
nvidia_modeset       1089536  0
nvidia              17633280  1 nvidia_modeset
ipmi_msghandler        65536  2 ipmi_devintf,nvidia
[mv@gaunt ~]$ sudo ./nvidia-management/disable-gpu.sh 
[sudo] password for mv: 
[mv@gaunt ~]$ lsmod | grep nvidia
[mv@gaunt ~]$ 

I have no idea though who exactly is to blame, if it's unigine valley going rogue with bumblebee or bumblebee not being able to terminate/kill the application correctly, although I guess it shouldn't need to kill the application.

Unity Valley has also been the only application to do this so far for me. Although I don't really have tested many applications yet.

Last edited by Morv (2019-03-21 11:30:52)

Offline

#130 2019-03-21 11:26:59

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

LazyLucretia wrote:

Well, here goes my dreams of finally being able to use optirun... After running unigine-valley for a while, I cannot unload nvidia because ipmi_msghandler somehow got loaded eventhough it was blocked in /etc/modprobe.d/disable-ipmi.conf . Back to nvidia-xrun I guess.

Good news everyone. It seems that this is an issue about unigine-valley not shutting down properly. After I killed valley_x64 process with `kill -9`, I was able to unload nvidia module.

Offline

#131 2019-03-21 11:41:55

Morv
Member
Registered: 2016-10-09
Posts: 14

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Haha, just as I finished my post tongue

Btw, I think it would be great if the instructions of post https://bbs.archlinux.org/viewtopic.php … 1#p1826641 would make it to the 9570 wiki page. I recently reinstalled my system and used these instructions to setup the nvidia stuff again and it just works perfectly fine.

Offline

#132 2019-03-21 11:50:54

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

I've just seen your reply as I was editing OP to include this solution. smile Yes I also think this should be in the wiki page. I'm going to create a wiki account now though I don't know if newly created users can edit wiki pages.

Last edited by LazyLucretia (2019-03-21 11:51:12)

Offline

#133 2019-03-21 13:52:11

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

If everyone agree, I will update the Archwiki Dell XPS 15 9570.. Notably with the Graff tuto that worked on my system.

Last edited by Yann (2019-03-21 13:54:27)


all different - all equal

Offline

#134 2019-03-22 06:55:32

LazyLucretia
Member
Registered: 2016-01-28
Posts: 39

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

As I said before, I had do use `modprobe nvidia` at the end of the enableGpu.sh script. In Graff's solution, running `nvidia-smi` does the same effect. So this should also be included in the wiki entry, either as a part of the solution or as a Note.

Yann wrote:

If everyone agree, I will update the Archwiki Dell XPS 15 9570.. Notably with the Graff tuto that worked on my system.

With this in mind, I agree, you can update the wiki page.

Last edited by LazyLucretia (2019-03-22 06:57:20)

Offline

#135 2019-04-18 21:49:54

Graff
Member
Registered: 2019-01-14
Posts: 4

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Great that this works for you guys.

@LazyLucerita I didn't noticed that, as I am using optirun to run applications which require GPU. After simply running enableGpu.sh, lsmod | grep nvidia returns nothing. This reproduces your case. I updated tutorial to add modprobe nvidia to enable script.

It is great idea to include this information in wiki, however please give credit to tyrells (who created scripts to load and unload gpu) and you guys. I merely gathered knowledge from this thread in form of that tutorial and added a few tips to problems connected to loading of modules, which I encountered smile

Last edited by Graff (2019-04-18 21:51:58)

Offline

#136 2019-04-19 15:00:33

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Hey,

I modified the Archwiki Dell XPS 15 9570 with these different steps:

  • add some precisions in the suspend section

  • add a UEFI section - copied from Dell XPS 15 9560

  • create a EFI firmware updates section

  • removed the last optimus NVIDIA section and create a new one with the conclusion of this current discussion

  • add a subsection for xbacklight not conflicting with NVIDIA optimus section in Troubleshooting

  • create the Power Management section with the Suspend and Hibernate sections + adding a new powertop section in it

  • changing Power Management from Buggy to Working


all different - all equal

Offline

#137 2019-04-21 07:33:38

CarbonFixer
Member
Registered: 2013-10-19
Posts: 19

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

I followed the instructions and now the system fails at the graphical boot stage.
This is the system message it stops at:

 iTCO_wdt iTCO_wdt: can't request region for resource [mem 0x00c5fffc-0x00c5ffff] 

I also uploaded the output of dmesg and journalctl.

Any ideas how to fix this?

Offline

#138 2019-04-21 08:01:01

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Hi CarbonFixer,

CarbonFixer wrote:

iTCO_wdt iTCO_wdt: can't request region for resource [mem 0x00c5fffc-0x00c5ffff]

is not a critical error. I have been having this error for a long time, tried to fix it but finally let it be.


Your issue is somewhere else. I noticed that your kernel version is 5.x (Linux version 5.0.8-arch1-1-ARCH). This is a known issue, look at this bug report [linux-kernel-5.x for xps-15 5970]. A patch has been made, should be integrated to the main line kernel in the next few weeks, we will have to be patient. Otherwise, if you are motivated, you can compile the kernel yourself with a patch (already released) and you should be fine, but you will have to do it for any new kernel release..

So, I think you are good, just downgrade your kernel version to the 4.20.x version. (the last 4.x one being the 4.20.13 is particuraly stable for me ..)

cd /var/cache/pacman/pkg

Check if you have the 4.20.x linux and linux-header versions:

ls -lart | grep -i linux-4.20
ls -lart | grep -i linux-headers-4.20

If so,

pacman -U linux-4.20.13.arch1-1-x86_64.pkg.tar.xz linux-headers-4.20.13.arch1-1-x86_64.pkg.tar.xz

(if you don't have them, let us know, we will download them from the arch archives)

I recommand to downgrade nvidia and nvidia-utils too, regarding your linux kernel version:

pacman -U nvidia-418.56-7-x86_64.pkg.tar.xz nvidia-utils-418.56-1-x86_64.pkg.tar.xz

If you use virtualbox, could be good to downgrade virtualbox-host-modules-arch too, otherwise, forget about it.

Then edit your /etc/pacman.conf file:

sudo vim /etc/pacman.conf

and edit the IgnorePkg line with the packages you don't want to be updated next time pacman update the system:

IgnorePkg   =linux linux-headers virtualbox-host-modules-arch nvidia nvidia-utils

Then reboot ...

Last edited by Yann (2019-04-21 08:14:15)


all different - all equal

Offline

#139 2019-04-21 08:35:42

CarbonFixer
Member
Registered: 2013-10-19
Posts: 19

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Thanks Yann. I tired your suggestion but I still get the same error. The kernel, headers and nvidia driver were all downgraded to the suggested versions and still sddm fails to load with the error of "Failed to read display number from pipe". I also tried booting with the lts kernel, to no avail. What can cause this?

Last edited by CarbonFixer (2019-04-21 08:36:42)

Offline

#140 2019-04-21 08:39:53

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Could you give the output of:

uname -a

sudo journalctl -p err

dmesg

Last edited by Yann (2019-04-21 08:41:34)


all different - all equal

Offline

#141 2019-04-21 08:53:02

CarbonFixer
Member
Registered: 2013-10-19
Posts: 19

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Sure. This is uname-a:
https://pastebin.com/VMXpEHKk

this is journalctl -p err:
http://ix.io/1E2H

and this is dmesg:
http://ix.io/1E2J

Edit: for brevity, here is also journalctl -b -p err:
http://ix.io/1E2K

Last edited by CarbonFixer (2019-04-21 08:56:27)

Offline

#142 2019-04-21 09:01:46

Morv
Member
Registered: 2016-10-09
Posts: 14

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Just a note: According to https://bugs.freedesktop.org/show_bug.cgi?id=109959 the black screen issue should be fixed with the backported patch into 5.0.8, so the problem here is something else.

Haven't tested myself yet though.

Last edited by Morv (2019-04-21 09:02:10)

Offline

#143 2019-04-21 09:02:53

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

ok. I don't use sddm, I just have i3wm with no DE. So I don't have this package installed.

Have you done all the steps in the Archwiki Dell XPS 15 9570?
Notably, have you disable nouveau and nvidia at boot?

lsmod | grep nouveau
lsmod | grep nvidia

What is the exact behavior now? Can you get to a console? Other tty?

Last edited by Yann (2019-04-21 09:03:31)


all different - all equal

Offline

#144 2019-04-21 09:06:40

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Thanks Morv for this precision. I just gave a try, one more time, few days ago with the same behavior (black screen).
I will test it OMT this week, if you do, please let us know.


all different - all equal

Offline

#145 2019-04-21 09:17:57

CarbonFixer
Member
Registered: 2013-10-19
Posts: 19

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Yann wrote:

ok. I don't use sddm, I just have i3wm with no DE. So I don't have this package installed.

Have you done all the steps in the Archwiki Dell XPS 15 9570?
Notably, have you disable nouveau and nvidia at boot?

lsmod | grep nouveau
lsmod | grep nvidia

What is the exact behavior now? Can you get to a console? Other tty?

I have found my incredibly stupid error in applying the instructions. I created the disable-ipmi.conf file in /etc/X11/xorg.conf.d instead of /etc/modprobe.d. sddm now loads fine, even with kernel 5.0.8. Thank you for all the help.

Offline

#146 2019-04-21 09:34:49

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Great!
So you confirm that the tuto on Archwiki Dell XPS 15 9570 works well for you? Even the optimus configuration?
And that the linux-5.0.8 boots well too?


all different - all equal

Offline

#147 2019-04-21 09:49:17

CarbonFixer
Member
Registered: 2013-10-19
Posts: 19

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Yann wrote:

Great!
So you confirm that the tuto on Archwiki Dell XPS 15 9570 works well for you? Even the optimus configuration?
And that the linux-5.0.8 boots well too?

Yes. I am now running a steam game using optirun.
I updated the wiki to emphasize where the ipmi changes should go.

Offline

#148 2019-04-21 09:54:27

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Great, so Morv was right.
I looked at your modifications, they are good, moreover, my /etc/modprobe.d/disable-ipmi.conf file conf already had these lines lol.
I missed that when writing this section.

Last edited by Yann (2019-04-21 09:55:10)


all different - all equal

Offline

#149 2019-04-23 07:34:10

Yann
Member
Registered: 2017-11-23
Posts: 152

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Upgraded to 5.0.9-arch1-1-ARCH and working like a charm. Thanks for the patch..


all different - all equal

Offline

#150 2019-04-27 15:05:26

snack
Member
From: Italy
Registered: 2009-01-13
Posts: 753

Re: [SOLVED] Dell XPS 9570 bbswitch not working, Nvdia won't power off/on

Hello everybody, first of all a big thank you for the fantastic job you people did for solving this problem. I set up my system following the Optimus instructions in the XPS 15 9570 wiki page but I get an error. I enabled the "modprobe nvidia" line in the enablegpu.sh sript since otherwise the nvidia module is not loaded. But now when I launch enablegpu,sh I get this error:

modprobe: ERROR: Error running install command for ipmi_devintf
modprobe: ERROR: could not insert 'nvidia': No such device

I am not an expert so I'd need some guidance to sort this out. I am using linux-ck-skylake 5.0.10-1 and nvidia-ck-skylake 2:418.56-7.
Thanks in advance.

Offline

Board footer

Powered by FluxBB