dell-xps-9560-ubuntu-respin icon indicating copy to clipboard operation
dell-xps-9560-ubuntu-respin copied to clipboard

[Ubuntu 18.04] prime-select intel is not powering off the nvidia card

Open GordianDziwis opened this issue 6 years ago • 85 comments

Thanks for feedback, hope it gets fixed soon!

stockmind avatar May 04 '18 12:05 stockmind

Manual workaround: https://wiki.archlinux.org/index.php/hybrid_graphics

soncodi avatar May 06 '18 05:05 soncodi

I can get Nvidia to power down with this script:

#!/bin/bash
echo "Switching off nvidia"

# move from Nvidia to intel graphics (if not already done)
prime-select intel

# switch of power to Nvidia (repeat after each laptop start)
echo "auto" > /sys/bus/pci/devices/0000\:01\:00.0/power/control

# Results in power down freeze, but seems needed? 
echo "1" > /sys/bus/pci/devices/0000\:01\:00.0/remove

After running this, sudo powertop shows me about ~6W instead of ~14W !

One nasty issue: the remove of the driver results in freeze during power down. Someone reported they did not need the remove and set power/control to auto was enough, but it was not for me...

tvld avatar May 15 '18 12:05 tvld

@tvld freeze during shutdown could be the result of the nouveau driver being loaded after switching to intel. Nouveau does not really work with 10xx gpus. Adding nouveau.modeset=0 as a bootparameter could help.

GordianDziwis avatar May 15 '18 12:05 GordianDziwis

@BonaBeavis my current grub line is:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_osi=Linux acpi_osi=! acpi_osi='Windows 2009' nouveau.runpm=0"

What does nouveau.modeset=0 add to that?

tvld avatar May 15 '18 13:05 tvld

@tvld It prevents the nouveau modul from loading, there was a change in prime. Prime now uses the nouveau modul for powering off the dgpu when in intel mode. Bug #1765363 “prime-select intel is not powering off the nvidia ...” : Bugs : nvidia-prime package : Ubuntu

GordianDziwis avatar May 15 '18 13:05 GordianDziwis

@BonaBeavis can you copy your total Grub line here? It makes no difference for me.

tvld avatar May 15 '18 14:05 tvld

You are right, maybe i915.modeset=1 is missing

GRUB_CMDLINE_LINUX_DEFAULT="quiet acpi_rev_override=1 enable_fbc=1 enable_psr=1 i915.modeset=1 disable_power_well=0 nouveau.modeset=0"

GordianDziwis avatar May 15 '18 14:05 GordianDziwis

Trying these kennel parameters killed my wifi. Is there anything you are doing to prevent that?

On Tue, May 15, 2018, 8:29 AM BonaBeavis [email protected] wrote:

You are right, maybe i915.modeset=1 is missing

GRUB_CMDLINE_LINUX_DEFAULT="quiet acpi_rev_override=1 enable_fbc=1 enable_psr=1 i915.modeset=1 disable_power_well=0 nouveau.modeset=0"

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/stockmind/dell-xps-9560-ubuntu-respin/issues/8#issuecomment-389187561, or mute the thread https://github.com/notifications/unsubscribe-auth/AACvYtVBR0j5UmpclocHOpPhoE2_8klDks5tyuY2gaJpZM4TwqE4 .

qhartman avatar May 15 '18 14:05 qhartman

I think those are the necessary ones:

GRUB_CMDLINE_LINUX_DEFAULT="quiet acpi_rev_override=1 i915.modeset=1 nouveau.modeset=0" 

Never had a wifi problem, but it is all trial and error with these boot parameters. Workarounds all the way down.

GordianDziwis avatar May 15 '18 14:05 GordianDziwis

Seems that this wasn't the wifi issue. My firmware somehow got nuked at the same time that I was making these parameter changes and I mis-attributed the failure.

qhartman avatar May 15 '18 15:05 qhartman

Running sudo powertop gave me a power usages of about 15W in idle, indicating that the GPU was still on, even after prime-select intel.

I kept powertop running and in another terminal ran:

$ cat /sys/bus/pci/devices/0000\:01\:00.0/power/control
# resulted in "on", which is not good

I then executed ( see bug report ):

sudo sh -c 'echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control'

Powertop dropped to about 6W ! )) So then it was simple, created this startup script to make the change permanent:

$ sudo nano /lib/systemd/system/gpuoff.service

And pasted contents:

[Unit]
Description=Power-off gpu

[Service]
Type=oneshot
ExecStart=/bin/bash -c "if [[ `prime-select query` == 'intel' ]]; then echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control; fi"



[Install]
WantedBy=default.target

To test the script you can run sudo systemctl start gpuoff.

If ok, run sudo systemctl enable gpuoff to enable the script to start on powerup.

To confirm that it works cat /sys/bus/pci/devices/0000\:01\:00.0/power/control should return: "auto" after reboot.

PS For what it is worth, my /etc/default/grub line is:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.modeset=1 nouveau.modeset=0"

tvld avatar May 15 '18 19:05 tvld

Great job all! :) @tvld can i add the service/script to the respin? This may help lot of people!

stockmind avatar May 16 '18 07:05 stockmind

@stockmind for sure, I have cleaned it up a bit.

tvld avatar May 16 '18 07:05 tvld

I ended up doing the same with bbswitch...

Can anyone comment on that the difference is between this method and installing bbswitch?

damageboy avatar May 17 '18 07:05 damageboy

@damageboy no idea; I did not try bbswitch... If it works for you a standard package might be better...

tvld avatar May 18 '18 09:05 tvld

How about

bash -c 'if [[ "`prime-select query`" == "intel" ]]; then echo auto > /sys/bus/pci/devices/0000\\:01\\:00.0/power/control ; fi'

luispabon avatar May 23 '18 11:05 luispabon

@luispabon Can do... but I dont see a problem with setting device power on "auto" in Nvidia mode as well?

tvld avatar May 23 '18 11:05 tvld

Actually there isn't. That was my script to explicitly turn it off changed to auto instead. As you were :+1:

luispabon avatar May 23 '18 14:05 luispabon

@luispabon I could be wrong, but I think the only two available modes are "auto" and "on". I thought "off" is not available ...

tvld avatar May 23 '18 14:05 tvld

Totally works here :+1:

luispabon avatar May 23 '18 14:05 luispabon

Thanks @tvld !

grafik

mablae avatar May 27 '18 00:05 mablae

Sorry for the silly question, is there any chance to switch back to Nvidia card, after applying @tvld 's solution?

nicobonne avatar May 28 '18 10:05 nicobonne

@nicobonne That is not a silly question: in my case, prime-select nvidia freezes my system on startup and I never see the login prompt.

That said, to be 100% sure it is not the start up script I have modified slightly to ensure the power settings are only applied when on intel mode as @luispabon already mentioned but I changed syntax:

ExecStart=/bin/bash -c "if [[ `prime-select query` == 'intel' ]]; then echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control; fi"

For me it does not matter... nvidia prevents the login prompt with or without the powersetting on 'auto'. I dont need Nvidia, so I did not spend time debugging. Maybe someone else can test if they can still get Nvidia to run? With the revised script line?

tvld avatar May 28 '18 12:05 tvld

@mablae I have the 54W battery, wifi on and bluetooth mouse, FHD screen at 50%. Your wakeup/s are very high... You must be running something? Did you install TLP ? screenshot from 2018-05-29 15-03-51

tvld avatar May 29 '18 13:05 tvld

That's really good power consumption. I've never seen it lower than 7w on mine. Do you have the FHD or UHD screen? Is this measured on an empty desktop session (eg no other apps other than the DE itself running)?

luispabon avatar May 29 '18 13:05 luispabon

@tvld I have the same problem. I don't believe X is correctly picking up the new graphics card.

luispabon avatar May 29 '18 13:05 luispabon

@luispabon I believe I can boot on Nvidia if I delete /etc/X11/xorg.conf... but I dont wanna go there. Very time consuming to debug this nonsense ;-)) Ps - Got FHD. I run the normal chat apps in the topbar but other than that no applications open of course. Nothing special though.

tvld avatar May 29 '18 13:05 tvld

Weirdly enough I have no xorg.conf per se, but another file. I'm not sure it's actually getting picked up and have no clue of where it came from:

~ cat /etc/X11/xorg.conf.11302017
Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"
EndSection

Section "Device"
    Identifier "intel"
    Driver "modesetting"
    BusID "PCI:0@0:2:0"
    Option "AccelMethod" "None"
EndSection

Section "Screen"
    Identifier "intel"
    Device "intel"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:1@0:0:0"
    Option "ConstrainCursor" "off"
EndSection

Section "Screen"
    Identifier "nvidia"
    Device "nvidia"
    Option "AllowEmptyInitialConfiguration" "on"
    Option "IgnoreDisplayDevices" "CRT"
EndSection

luispabon avatar May 29 '18 13:05 luispabon

Did you ever run nvidia-xconfig ? I suspect Nvidia is switching xorg.conf on and off...

But without an active xorg.conf, I dont understand why you get black screen after prime-select nvidia. Can you try to reboot twice instead of once after changing? And what is your grub line?

tvld avatar May 29 '18 13:05 tvld

Rebooting twice unfortunately still results on a black screen.

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash acpi_rev_override=5 nouveau.runpm=0 disable_power_well=0  blacklist.nouveau=1"

luispabon avatar May 29 '18 14:05 luispabon

@tvld Yes, I think I had Jetbrains PhpStorm IDE open in background when making the screenshot.

mablae avatar May 29 '18 14:05 mablae

@luispabon As far as I understood you need to remove the acpi_rev_override=1 after switching to intel.

Did you run sudo update-grub to apply the changes to /etc/default/grub ?

mablae avatar May 29 '18 14:05 mablae

Yes, of course. I find acpi_rev_override=5 works way better than 1 in terms of suspend/resume.

I don't see how that would break nvidia? I had Ubuntu 17.10 on the same grub settings working fine with bbswitch and bumblebee.

luispabon avatar May 29 '18 14:05 luispabon

I am no expert, just guessing. Mine wasn't showing Desktop after Login having acpi_rev_override=1 AND nvidia driver loaded. Maybe it was just a strange coincidence and I attributed it wrong ?

I am happy now, dont need nvidia at all.

mablae avatar May 29 '18 15:05 mablae

@tvld thank you so much mate, really needed. No high battery drain problems anymore.

atzo92 avatar Aug 05 '18 14:08 atzo92

@atzo92 you're welcome... it's still far from elegant but at least on Intel it has been running smooth since for me :-)

tvld avatar Aug 06 '18 07:08 tvld

@tvld Want to add my thanks as well. I tried messing around with getting bumblebee working on my precision 5510 laptop, but it was a big headache. Your solution works great. It's nice to have a cool laptop under my hands.

pweisdepp avatar Aug 08 '18 20:08 pweisdepp

@luispabon I had black screen issue on the 9570. What fixed it for me was updating to latest linux kernel and running nvidia-driver-396. Note the newest linux kernel was recently release 4.18, and I have not tested it. I running the last stable release before that, 4.17.12-041712-generic.

pwaterz avatar Aug 14 '18 12:08 pwaterz

Thank you @pwaterz for the heads up. Funnily enough I tried it again without upgrading and it now works fine - after restarting I get to the desktop and the gpu is being used.

luispabon avatar Aug 15 '18 10:08 luispabon

@luispabon You're welcome! I personally had an issue where the screen with freak out and start flashing different colors. Kernel update fixed it. I haven't seen anyone else having that issue. I have a newer XPS 9570 and I think i have a rev'ed 1050ti.

pwaterz avatar Aug 15 '18 12:08 pwaterz

Likely yeah, the 9560 has a regular GTX1050 and perhaps other differences.

luispabon avatar Aug 15 '18 13:08 luispabon

Thanks a lot, this succesfully turned my nvidia graphics card off. However, now I would like revert the changes to use the graphics cards but I can't detect it anymore. I ran: echo "auto" > /sys/bus/pci/devices/0000\:01\:00.0/power/control echo "1" > /sys/bus/pci/devices/0000\:01\:00.0/remove And now lspci -k does not show the graphics card. Any help on how I can send power to the GPU again?

schreven avatar Sep 04 '18 06:09 schreven

@schreven Don't use these two echo's but leave it on default settings?

tvld avatar Sep 04 '18 08:09 tvld

@tlvd You mean I just don't use the commands? Don't the commands, especially the second one, stay even after a reboot? ps: Bear with me, I have been using ubuntu for 2 weeks

schreven avatar Sep 07 '18 11:09 schreven

@schreven Just that new to Ubuntu? Then I am sorry you are running into about the only problem that is a pain in the @#$ for me, even after 10 years of ubuntu. Other than this one it's all smooth and great for us ))

That said, in theory, all you need to do is run sudo prime-select nvidia in a terminal and reboot. ( The if [[ `prime-select query` == 'intel' ]] in the boot up script, means the commands only executes if you are on intel, that is after you run sudo prime-select intel )

Again, in theory, you should be back on Nvidia but ..well... it is a nasty bug for a reason.. Fingers crossed and let us know ;)

tvld avatar Sep 07 '18 11:09 tvld

Just to report back on Bionic, this service works just fine. Re-enabling nvidia using prime-select also works fine. Battery life on my 4K model at around 7-8h.

May I recommend to apply this service when -c is set to bionicbeaver?

luispabon avatar Sep 25 '18 14:09 luispabon

Hi, I have just came across some activities on that subject https://discourse.ubuntu.com/t/call-for-testing-nvidia-prime-in-ubuntu-18-04-and-18-10/8207 I cannot test it myself but I think It was worth mentionning here. These "proposed" packages could be a breakthrough !

PascalNoisette avatar Oct 02 '18 09:10 PascalNoisette

I think this has been fixed in Ubuntu 18.10. Install and boot was fine but the system completely froze (multiple times) after using it for a few minutes. Used nouveau.modeset=0 temporarily and installed nvidia drivers and prime-select intel gives $ cat /sys/bus/pci/devices/0000:01:00.0/power/control = auto, so i think its working? sudo powertop also went down from 21 W to 13W on a default install, aned everything is flawless so far. Even noticed an option to launch an app using the dedicated graphics card in the right click menu when using the nouveau driver (which I didnt try since the system kept freezing on nouveau and was unusable). I have been trying to switch to Ubuntu on my main laptop since 16.04, I think I can finally use it without banging my head against a wall trying to figure things out with installation and booting and other basic stuff.

CognitiveMango avatar Oct 18 '18 20:10 CognitiveMango

This problem can appear after things have been running for a bit since it depends on pretty specific device states to get triggered. If you could run a bit longer and report back we'd all appreciate it.

On Thu, Oct 18, 2018 at 2:06 PM Kannan Pillappan [email protected] wrote:

I think this has been fixed in Ubuntu 18.10. Install and boot was fine but the system completely froze (multiple times) after using it for a few minutes. Used nouveau.modeset=0 temporarily and installed nvidia drivers and prime-select intel gives $ cat /sys/bus/pci/devices/0000:01:00.0/power/control = auto, so i think its working? sudo powertop also went down from 21 W to 13W on a default install, aned everything is flawless so far. Even noticed an option to launch an app using the dedicated graphics card in the right click menu when using the nouveau driver (which I didnt try since the system kept freezing on nouveau and was unusable). I have been trying to switch to Ubuntu on my main laptop since 16.04, I think I can finally use it without banging my head against a wall trying to figure things out with installation and booting and other basic stuff.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/stockmind/dell-xps-9560-ubuntu-respin/issues/8#issuecomment-431142628, or mute the thread https://github.com/notifications/unsubscribe-auth/AACvYtFShG3dNSLs-VRPCzKeXBOQchAkks5umN8-gaJpZM4TwqE4 .

qhartman avatar Oct 18 '18 20:10 qhartman

Have you noticed that when you set your nvidia bus control power to auto, you are not able to switch back to your nvidia, as if the nvidia modules were never available in the first place.

After a reboot with your nvidia as your profile, everything gets back to "normal".

JeffLabonte avatar May 02 '19 01:05 JeffLabonte

Running sudo powertop gave me a power usages of about 15W in idle, indicating that the GPU was still on, even after prime-select intel.

I kept powertop running and in another terminal ran:

$ cat /sys/bus/pci/devices/0000\:01\:00.0/power/control
# resulted in "on", which is not good

I then executed ( see bug report ):

sudo sh -c 'echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control'

Powertop dropped to about 6W ! )) So then it was simple, created this startup script to make the change permanent:

$ sudo nano /lib/systemd/system/gpuoff.service

And pasted contents:

[Unit]
Description=Power-off gpu

[Service]
Type=oneshot
ExecStart=/bin/bash -c "if [[ `prime-select query` == 'intel' ]]; then echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control; fi"



[Install]
WantedBy=default.target

To test the script you can run sudo systemctl start gpuoff.

If ok, run sudo systemctl enable gpuoff to enable the script to start on powerup.

To confirm that it works cat /sys/bus/pci/devices/0000\:01\:00.0/power/control should return: "auto" after reboot.

PS For what it is worth, my /etc/default/grub line is:

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash i915.modeset=1 nouveau.modeset=0"

@tvld I tried to apply your code and it seemd to work. But now, after a reboot I do not see the login page, only a black screen. How can I do to revert it? Ubuntu 18.04 on HP Zbook G5 with Nvidia Quadro P2000

Thanks in advance

clausmichele avatar Jul 15 '19 15:07 clausmichele

@clausmichele Sorry to hear. Did you check you Grub line? Also, I would think that 19.04 handles these issues better. Did you try to install that, e.g. the latest, Ubuntu version?

tvld avatar Jul 16 '19 08:07 tvld

I have to stick with 18.04 for compatibility of other software and drivers. Anyway, I've already reinstalled it and I'll use only the first command, which should not modify anything in the system, I'll just run it every time that I need it. sudo sh -c 'echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control'

clausmichele avatar Jul 16 '19 09:07 clausmichele

I would not be surprised if the command runs a bit too quickly after startup, as it works ok when you execute yourself, so a small "sleep" might help.. Anyway, good luck

tvld avatar Jul 16 '19 10:07 tvld

To save other people from going down the rabbit hole, I just wanted to check in here and let you know that as of 19.04, everything works great immediately after install with zero tweaks, including network. The only special thing I did was boot from the "safe graphics" option in the installer's GRUB list (otherwise I sometimes got a black screen, and once got a frozen session). With keyboard backlight off and screen at min brightness, I'm idling at ~6.5W, woohoo!

mogul avatar Jul 29 '19 03:07 mogul

@mogul Excellent news. Thank you for reporting here. I hesitated to upgraded my 18.04 only because of this reason. Now I will be brave and do a fresh install soon ))

tvld avatar Jul 29 '19 08:07 tvld

@mogul was that a fresh install of 19.04 or an upgrade off a respun ISO?

ghost avatar Jul 30 '19 02:07 ghost

I just did a fresh install of 19.04 and yes! ... All worked straight out of the box on my XPS15 9560 FHD.

My idle power usage with 50% screen, WiFi and Bluetooth on:

Without TLP:

  • Nvidia/Prime: 9.84 W
  • Intel: 6.26 W

With TLP installed:

  • Nvidia/Prime: 8.65W
  • Intel: 5.51 W (on 18.04 was reaching 4.65W though.)

Basically, Intel in idle gives me 30% more battery time. In practice this might be a bit more as the fans seem more aggressive with Nvidia.

tvld avatar Jul 31 '19 13:07 tvld

FYI, you can undervolt Intel CPU with undervolt.py

I use: --core -150 --cache -150 --gpu -100

for my Dell XPS 9560, which saves a bit more...

damageboy avatar Jul 31 '19 14:07 damageboy

@damageboy do you have measurements ?

tvld avatar Jul 31 '19 19:07 tvld

No, I did it a long time ago, but I remember a 5%+ improvement with 50% brightness, don't have it written / logged anywhere...

damageboy avatar Aug 01 '19 10:08 damageboy

Can confirm undervolt --core -150 --cache -150 --gpu -100 works also on my 9560 and seems to save indeed 10C, and the Joules that go with it.

tvld avatar Aug 02 '19 11:08 tvld

@tvld is that running on intel or nvidia graphics?

luispabon avatar Aug 02 '19 12:08 luispabon

@luispabon what, the 10C? Seems on both. But it did not help me a lot. I was hoping I could get the fan under 3000rpm as that is a real noise threshold for me, during working with Nvidia but that only happens in absolute idle. Normal work I sadly am back to Intel now...

tvld avatar Aug 02 '19 15:08 tvld

just did a fresh install of 19.04 on my 9560 (4k monitor) and it worked flawlessly. getting about ~7W running idle with prime intel profile selected, brightness turned all the way down, and bluetooth off.

ghost avatar Aug 03 '19 14:08 ghost

To those who did a fresh install of 19.04, I have a couple of questions. Do you mean the respun version of it or just the standard ISO? Does multi-monitor work out of the box? And could the fact that I am running dual boot affect this in any way?

markkosorus avatar Aug 05 '19 08:08 markkosorus

@mablae :
1- standard ISO 2- multi monitor works great, using it every day 3- no clue. Never liked multiboot myself so never used that setup

tvld avatar Aug 05 '19 09:08 tvld

Thanks @tvld! I'll give 19.04 a shot on dual boot and post an update.

markkosorus avatar Aug 05 '19 09:08 markkosorus

Vanilla 19.04 works fine on the laptop. Including multimonitor - I've tried dp over thunderbolt and hdmi (3 displays inc laptop), and also via thunderbolt dock (tb16, also 3 displays). All good. Can't say about dual boot as I needed full disk encryption, so had to nuke the whole system.

luispabon avatar Aug 05 '19 09:08 luispabon

@markkosorus i have my xps dual booted with windows and it all works without any issues

ghost avatar Aug 05 '19 14:08 ghost

@paulyu99 yeah, was about to post an update. 19.04 works out of the box on dual boot.

markkosorus avatar Aug 05 '19 14:08 markkosorus

The power control worked on my XPS 15 9570 with UHD 4K touch screen, 18.04LTS. With the NVidia hardware disabled I saved some 20 Watts. I checked with powertop to see what further savings were possible. After the NVidia turnoff I was at 12.8 W with display intensity on max, connected HDMI 1920x1200 display, USB mouse, USB keyboard. No browser or additional app running.

  • Reducing brightness to "decent level" -> 9.3W
  • Pulling HDMI cable -> 6.49W
  • Removing USB Mouse + Kb -> 6.26W = insignificant
  • Wifi off, Screen brightness down to minimal setting -> 4.33 W ! So, screen intensity contributes a lot.

mobimation avatar Aug 05 '19 16:08 mobimation

The solution pointed by @tvld worked flawlessly until kernel 4.15.0-54. For kernel 4.15.0-58 even after running echo auto > /sys/bus/pci/devices/0000\:01\:00.0/power/control the power consumption is still high (~20W). Curiously running cat /sys/bus/pci/devices/0000\:01\:00.0/power/control will still return "auto".

Is anyone facing the same issue?

naschpitz avatar Aug 29 '19 16:08 naschpitz

Installed Ubuntu 19.10. Sad to say, my idle CPU on Intel only raised with 15% to 7W. I dont know what causes yet, but first glance seemed that tick_sched_timer is high in powertop. Will monitor a bit. Did anybody else see a power raise after upgrading?

tvld avatar Nov 01 '19 23:11 tvld

Ok, found the culprit, it seems.

After I upgraded to 19.10, I got flooded with syslog errors with Nvidia enabled or on-demand: PCIE Bus Error: Severity=Corrected after booting into Ubuntu. To get rid of those, I edited /etc/default/grub to contain GRUB_CMDLINE_LINUX_DEFAULT="quiet splash pci=nomsi". That helped, the errors no longer appeared...

But now I know that this also shot up my power consumption. So, today, I removed the pci-nomsi and now we are to an astonishing great 3.74W with 50% display and BT mouse!

Screenshot from 2019-11-02 11-36-59

So, for now, can not use Nvidia at all, unless I change the grub every time... bummer :( See what Nvidia has to say.

tvld avatar Nov 02 '19 10:11 tvld

Ok, found the culprit, it seems.

After I upgraded to 19.10, I got flooded with syslog errors with Nvidia enabled or on-demand: PCIE Bus Error: Severity=Corrected after booting into Ubuntu. To get rid of those, I edited /etc/default/grub to contain GRUB_CMDLINE_LINUX_DEFAULT="quiet splash pci=nomsi". That helped, the errors no longer appeared...

But now I know that this also shot up my power consumption. So, today, I removed the pci-nomsi and now we are to an astonishing great 3.74W with 50% display and BT mouse!

Screenshot from 2019-11-02 11-36-59

So, for now, can not use Nvidia at all, unless I change the grub every time... bummer :( See what Nvidia has to say.

That's great! So did you create two Grub configurations, so you can reboot and pick "with nVidia" or "without nVidia"?

advance512 avatar Nov 24 '19 15:11 advance512

So this bug is not valid on 19.10 anymore with stock Ubuntu. I don't run any workarounds anymore, all 190% stock.

On Sun, 24 Nov 2019, 15:11 Alon Diamant, [email protected] wrote:

Ok, found the culprit, it seems.

After I upgraded to 19.10, I got flooded with syslog errors with Nvidia enabled or on-demand: PCIE Bus Error: Severity=Corrected after booting into Ubuntu. To get rid of those, I edited /etc/default/grub to contain GRUB_CMDLINE_LINUX_DEFAULT="quiet splash pci=nomsi". That helped, the errors no longer appeared...

But now I know that this also shot up my power consumption. So, today, I removed the pci-nomsi and now we are to an astonishing great 3.74W with 50% display and BT mouse!

[image: Screenshot from 2019-11-02 11-36-59] https://user-images.githubusercontent.com/986182/68069809-b8796b00-fd65-11e9-9d04-6b132d66456a.png

So, for now, can not use Nvidia at all, unless I change the grub every time... bummer :( See what Nvidia https://devtalk.nvidia.com/default/topic/1065906/linux/ubuntu-upgrade-from-19-04-gt-19-10-amp-enabling-nvidia-435-floods-quot-pcie-bus-error-severity-corrected-quot-/ has to say.

That's great! So did you create two Grub configurations, so you can reboot and pick "with nVidia" or "without nVidia"?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/stockmind/dell-xps-9560-ubuntu-respin/issues/8?email_source=notifications&email_token=ABQXYVZ5GZ5ZYV2QYLCM66LQVKKT3A5CNFSM4E6CUE4KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEFANQAY#issuecomment-557897731, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABQXYV3USZE4LPLOQTLSGGLQVKKT3ANCNFSM4E6CUE4A .

luispabon avatar Nov 24 '19 15:11 luispabon

@luispabon no " syslog errors with Nvidia" ?

tvld avatar Nov 25 '19 08:11 tvld

Nothing that I can see when I enable the driver. I get some when I connect my TB16 dock though, but doesn't seem to impede operation.

luispabon avatar Nov 25 '19 10:11 luispabon

@luispabon @tvld do you want mind offering a "bottom line" for this entire thread, specifically focused on Ubuntu 19.10? What is the current recommended configuration for power saving, how do you re-enable the nVidia GPU?

What is the configuration you're using on your own machine?

Thank you!

advance512 avatar Dec 06 '19 22:12 advance512

@advance512 for myself I don't have a bottom line for Ubuntu 19.10 Nvidia on XPS15. Two grubs is not really feasible. For now, sad to say I dont use Nvidia. ( Recommendation: bought other new HP laptop with AMD's new chips and all graphics work out of the box blazing fast. So until Dell get it's act together, no more Dell or Nvidia for our company )

tvld avatar Dec 07 '19 09:12 tvld

Of course. Laptop runs fine on 19.10 default installation, including recommended nvidia drivers (nvidia-435) which are also installed during system installation (if from scratch). Some notes:

  • No need for any custom kernel boot parameters, for instance to ensure suspend/resume works (no acpi_rev_override for instance)
  • Switch back and forth using prime-select
  • If you're using gnome, it only requires you to log out & back in, not a reboot. It basically requires X to restart. I'm not sure how this works in gnome wayland since I'm a sway user
  • If you do not want the nvidia drivers installed (or you must at some point reboot with the driver uninstalled for whatever reason), you must blacklist nouveau. The driver simply won't work on this GTX 1050 and the system will bot to a blank screen. This is the only custom config I've needed.
/etc ~ ack nouveau 
modprobe.d/blacklist-nouveau.conf
1:blacklist nouveau
2:options nouveau modeset=0

I haven't yet tried the new optimus-like gpu offloading (requires a newer version of X as well as the nvidia driver). I'm unsure if it's even compatible with pre 2xxx series. Something to check out for 20.04.

luispabon avatar Dec 07 '19 14:12 luispabon

Feeling all giddy, I tried booting stock 19.10 on my 9560 and it wouldn't even boot.  Did you have to do anything special to get it installed?  I've had some ups and downs on the respun 17.10, and was excited to move on.

Cheers,

*Jeff LaCoursiere*

STRATUSTALK, INC. / CTO

Phone: +1 703.496.4990 x108 Mobile: +1 815.546.6599 Email: [email protected] mailto:[email protected] Website: https://www.stratustalk.com Address: One Freedom Square 13th Floor Reston, VA 20190

https://www.facebook.com/jeff.lacoursiere https://linkedin.com/in/jeff-lacoursiere-884361 https://www.twitter.com/stratustalk

On 12/7/19 8:21 AM, Luis Pabon wrote:

Of course. Laptop runs fine on 19.10 default installation, including recommended nvidia drivers (nvidia-435) which are also installed during system installation (if from scratch). Some notes:

  • No need for any custom kernel boot parameters, for instance to ensure suspend/resume works (no |acpi_rev_override| for instance)
  • Switch back and forth using |prime-select|
  • If you're using gnome, it only requires you to log out & back in, not a reboot. It basically requires X to restart. I'm not sure how this works in gnome wayland since I'm a sway user
  • If you do not want the nvidia drivers installed (or you must at some point reboot with the driver uninstalled for whatever reason), you must blacklist nouveau. The driver simply won't work on this GTX 1050 and the system will bot to a blank screen. This is the only custom config I've needed.

|modprobe.d/blacklist-nouveau.conf 1:blacklist nouveau 2:options nouveau modeset=0 |

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/stockmind/dell-xps-9560-ubuntu-respin/issues/8?email_source=notifications&email_token=AINPWYB7CIPGEYQ4S54HN3LQXOWPXA5CNFSM4E6CUE4KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEGGH25Y#issuecomment-562855287, or unsubscribe https://github.com/notifications/unsubscribe-auth/AINPWYHVS5TBE5VNYKEAMUDQXOWPXANCNFSM4E6CUE4A.

lacoursj avatar Dec 08 '19 13:12 lacoursj

@lacoursj It should do boot just fine. I have latest BIOS, so you might check if you need to upgrade? Further, I think I have Legacy Boot setting in BIOS on.

tvld avatar Dec 09 '19 09:12 tvld