Weirdly, the first couple times I tried to run `optimus-manager --switch nvidia` it either didn't switch to nvidia (and just stayed on intel) or I got a blackscreen. But now it seems stable.
]]>The speciality regarding the external monitor seems to be a bug, or firmware quirk of this particular laptop model, and would hopefully be more properly resolved with firmware updates of said laptop model.
I would be perfectly content just using Intel graphics without optimus if it was possible to use HDMI. But the wiki is unclear (https://wiki.archlinux.org/index.php/Le … us_Manager) as to whether this is possible and how to achieve it. (From what I understand the HDMI input is wired directly to the Nvidia GPU, so something must be done to either treat Nvidia GPU as passthrough to Intel GPU or to use Nvidia GPU for monitor).
I'm not sure whether "This has been confirmed to work with the HDMI port." refers to (A) using optimus-manager in general or (B) "When using just the intel driver, disable the NVIDIA card manually:".
But it sounds from what you say that this is not going to work either way until bug fix / firmware update for X1 Extreme Gen 2 is available... Is that correct?
]]>The thing you are pointing out is dynamic render offload in the same xorg session dynamically (exporting a environment variable before running an application you want on the GPU). Which is incidentally something nvidia has implemented in the latest driver. However it currently needs a patched xorg, and doesn't support power management for pre Turing GPUs
Edit: Wait misread your link, that would be running on the intel card and dynamically adding the nvidia driver to control another display, this doesn't work indeed, however offloading the entire rendering to nvidia and then adding the screen should still make this work.
]]>
When switching via optimus-manager --switch nvidia (which is something I've not yet seen used in this entire thread.) it will juggle xorg configs around and load nvidia PRIME offload on the next login/the next boot.
Wouldn't this mean it doesn't work at all? Because I would assume this to be fact right now https://devtalk.nvidia.com/default/topi … 1/#5375031
On the other hand it seems to work under some circumstances and the explanation for this behavior might solve OPs problem. Sorry, I think I stepped into something I do not fully understand myself.
optimus-manager starts out in intel mode: Which means start xorg on intel and use nouveau for power management/disablement of the discrete card, you can configure that in /etc/optimus-manager/optimus-manager.conf to use bbswitch or nothing instead.
When switching via optimus-manager --switch nvidia (which is something I've not yet seen used in this entire thread.) it will juggle xorg configs around and load nvidia PRIME offload on the next login/the next boot.
Either way, the only files you will see actively change (because they are the ones that matter and cannot entirely be controlled dynamically) are xorg.configs which switch between intel only/and intel and nvidia offloading modes (all blacklists can and do remain, because they prevent automatic loading so optimus-manager can do it's thing.
The speciality regarding the external monitor seems to be a bug, or firmware quirk of this particular laptop model, and would hopefully be more properly resolved with firmware updates of said laptop model.
]]>Maybe go back a step and disable the manager. Instead load the nvidia driver yourself and confirm whether it works or not.
If it does you probably should file a bug report for optimus-manager and I think a udev rule might work instead for the time being.
Unfortunately Nvidia is still Nvidia and it looks like they do not support PRIME offloading for this use-case.
]]>UPDATE: this could be related to whether I had the monitor plugged in during boot or not... not sure
]]>If I alter the refresh rate of the monitor, it then renders correctly (not black anymore, I see my screens / desktop) but it does not refresh afterwards, so the image I see on my monitor is static/stale/out-of-date. I saw that this may be a VSYNC issue, but not sure how I should resolve. Mouse does get redrawn / refreshed correctly, but nothing else does.
And lsmod still shows nouveau being loaded... which confuses me
]]>I blacklisted nouveau in /etc/modprobe.d/nouveau.conf and got Arch installed and running SDDM/KDE Plasma via the xf86-video-intel driver. At this point, running lsmod | grep nouveau had no output, so I think nouveau was being blacklisted correctly.
However, I wanted to use the HDMI port to connect to an external monitor. From the wiki on my machine (https://wiki.archlinux.org/index.php/Le … me_(Gen_2)), it seems that using optimus-manager is the recommended approach. I installed the nvidia driver and optimus-manager and rebooted. But now, lsmod | grep nouveau shows that nouveau is being loaded and lspci -k shows:
$ lspci -k | grep -A -E "(VGA|3D)"
01:00.0 VGA compatible controller: NVIDIA Corporation Device 1f91 (rev a1)
Subsystem: Lenovo Device 229f
Kernel driver in use: nouveau
Kernel modules: nouveau, nvidia_drm, nvidia
I would have expected the Kernel driver in use to be nvidia.
I followed the advice from a related post (https://bbs.archlinux.org/viewtopic.php … 3#p1103093), but 1) nouveau is not listed in my MODULES 2) I already blacklisted nouveau and 3) the only file in /etc/X11/xorg.conf.g/ is 10-optimus-manager.conf which to me looks correct:
Section "Device"
Identifier "intel"
Driver "modesetting"
BusID "PCI:0:2:0"
Option "DRI" "3"
EndSection
Once thing I found confusing is that usr/lib/modprobe.d/optimus-manager.conf blacklists not just nouveau, but also nvidia. Though I think this might be because currently I have optimus in "intel" mode, so if I switch to nvidia mode I'm guessing this file would change.
Anyway, the problem is that:
1) nouveau is being loaded and used as the driver for my Nvidia card even though its blacklisted and I have nvidia driver installed and
2) connecting to an external monitor via HDMI either causes both displays to go black or freeze
3) running lspci -k sometimes freezes (...because nouveau is loaded I think)
I also tried to run the suggested commands for Optimus when using only Intel graphics (https://wiki.archlinux.org/index.php/Le … us_Manager):
# tee /sys/bus/pci/devices/0000\:01\:00.1/remove <<<1
# tee /sys/bus/pci/devices/0000\:01\:00.0/remove <<<1
This made a display manager control pop up when I plugged in the HDMI, but when viewing the Displays system settings module, my machine does not detect the external monitor.
]]>