No HDMI in Nvidia on-demand mode

Bug #2033735 reported by Francois Thirioux
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Confirmed
Undecided
Unassigned
nvidia-graphics-drivers-535 (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Hi,

Legion laptop with Nvidia.
- Nouveau : no hdmi
- Nvidia 535 dynamic graphics : no HDMI (screen not detected)
- Nvidia 535 discrete graphics : HDMI is detected

So I suppose this bug to be linked to Intel GPU.

All was ok with previous 6.3 kernel.
---
ProblemType: Bug
ApportVersion: 2.27.0-0ubuntu2
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: fthx 3395 F.... wireplumber
 /dev/snd/controlC1: fthx 3395 F.... wireplumber
 /dev/snd/seq: fthx 3390 F.... pipewire
CasperMD5CheckResult: pass
CurrentDesktop: ubuntu:GNOME
DistroRelease: Ubuntu 23.10
InstallationDate: Installed on 2021-09-15 (723 days ago)
InstallationMedia: Ubuntu 21.10 "Impish Indri" - Alpha amd64 (20210910)
MachineType: {report['dmi.sys.vendor']} {report['dmi.product.name']}
NonfreeKernelModules: nvidia_modeset nvidia
Package: linux (not installed)
ProcEnviron:
 LANG=fr_FR.UTF-8
 PATH=(custom, no user)
 SHELL=/bin/bash
 TERM=xterm-256color
 XDG_RUNTIME_DIR=<set>
ProcFB: 0 i915drmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-6.5.0-5-generic root=/dev/mapper/vgubuntu-root ro quiet splash vt.handoff=7
ProcVersionSignature: Ubuntu 6.5.0-5.5-generic 6.5.0
RelatedPackageVersions:
 linux-restricted-modules-6.5.0-5-generic N/A
 linux-backports-modules-6.5.0-5-generic N/A
 linux-firmware 20230815.git0e048b06-0ubuntu1
Tags: mantic wayland-session
Uname: Linux 6.5.0-5-generic x86_64
UpgradeStatus: Upgraded to mantic on 2023-03-06 (186 days ago)
UserGroups: adm cdrom dip lpadmin lxd plugdev sambashare sudo vboxusers
_MarkForUpload: True
dmi.bios.date: 07/10/2023
dmi.bios.release: 1.54
dmi.bios.vendor: LENOVO
dmi.bios.version: J2CN54WW
dmi.board.asset.tag: NO Asset Tag
dmi.board.name: LNVNB161216
dmi.board.vendor: LENOVO
dmi.board.version: SDK0T76461 WIN
dmi.chassis.asset.tag: NO Asset Tag
dmi.chassis.type: 10
dmi.chassis.vendor: LENOVO
dmi.chassis.version: Legion 5 Pro 16IAH7H
dmi.ec.firmware.release: 1.54
dmi.modalias: dmi:bvnLENOVO:bvrJ2CN54WW:bd07/10/2023:br1.54:efr1.54:svnLENOVO:pn82RF:pvrLegion5Pro16IAH7H:rvnLENOVO:rnLNVNB161216:rvrSDK0T76461WIN:cvnLENOVO:ct10:cvrLegion5Pro16IAH7H:skuLENOVO_MT_82RF_BU_idea_FM_Legion5Pro16IAH7H:
dmi.product.family: Legion 5 Pro 16IAH7H
dmi.product.name: 82RF
dmi.product.sku: LENOVO_MT_82RF_BU_idea_FM_Legion 5 Pro 16IAH7H
dmi.product.version: Legion 5 Pro 16IAH7H
dmi.sys.vendor: LENOVO

Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 2033735

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Francois Thirioux (fthx) wrote : AlsaInfo.txt

apport information

tags: added: apport-collected mantic wayland-session
description: updated
Revision history for this message
Francois Thirioux (fthx) wrote : CRDA.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : CurrentDmesg.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : IwConfig.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Lspci.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Lspci-vt.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Lsusb.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Lsusb-t.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Lsusb-v.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : ProcInterrupts.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : ProcModules.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : RfKill.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : UdevDb.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : WifiSyslog.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : acpidump.txt

apport information

Revision history for this message
Francois Thirioux (fthx) wrote : Re: [mantic] New 6.5.0.2 kernel + Intel GPU = no HDMI

Still here with latest 6.5.0.5

Changed in linux (Ubuntu):
status: Incomplete → New
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Francois Thirioux (fthx) wrote : Re: [mantic] New 6.5.0.2 kernel + Intel GPU = no HDMI

When I boot with Intel dynamic graphics, the NVidia GPU seems to be not detected: Ubuntu drivers does not offer to add any proprietary driver.

Revision history for this message
Francois Thirioux (fthx) wrote :

Still here with latest 6.5.0.6 (kernel 6.5.3).

Tested with Nouveau, so no Nvidia 535 driver.
HDMI screen is not even detected. Same behavior using an USB-c dock (hdmi + dp after that).

Revision history for this message
Juerg Haefliger (juergh) wrote :

I'm confused by this report. What exactly is working as expected and what is not?

Revision history for this message
Francois Thirioux (fthx) wrote :

At the moment, with latest 6.5 Ubuntu kernel:
- dynamic graphics: hdmi or usb-c (then hdmi and dp) monitors are not detected, whatever I use Nouveau or Nvidia 535
- discrete graphics: all is ok, Nouveau or Nvidia

In GNOME settings/display, when I use dynamic graphics (Intel here), I don't see anything but my laptop's screen. Using dynamic graphics, my laptop screen is ok.

This bug started when upgraded from 6.3 to 6.5 kernel.

Revision history for this message
Francois Thirioux (fthx) wrote :

Additionally, without any monitor connected:
- using dynamic graphics and Nouveau and 6.5.0-6 kernel does not boot (hang after disk pwd prompt was ok)
- using dynamic graphics and Nouveau and 6.5.0-5 kernel does boot but GNOME does not offer me to start an app using dGPU (and GNOME settings shows only Intel as my gpu, not both Intel+NV174)

Plug my hdmi monitor after GNOME is started, using dGPU mode only + Nouveau makes the system crash (only magic keys work here).

I'm not a newbie but that's quite a mess!
:-)

Revision history for this message
Francois Thirioux (fthx) wrote :

Same issue using 6.6 from Unstable PPA.

Using intel session in current 6.5 kernel (on-demand mode in Nvidia params), the Nvidia GPU is simply not detected. I cannot launch an app using Nvidia gpu in GNOME app menu.
And maybe some ports like hdmi are linked to the Nvidia GPU.

Using Intel session with no nvidia driver (so Nouveau used), I even cannot install the Nvidia driver because Ubuntu drivers tell me there's no additional driver available.

Revision history for this message
Francois Thirioux (fthx) wrote :

Forgot to mention: in Windows 11, on-demand is working with hdmi monitors.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I don't think this is a bug. When the Nvidia GPU is disabled it is expected that the ports wired to it will also be disabled.

Changed in linux (Ubuntu):
status: Confirmed → Opinion
Revision history for this message
Francois Thirioux (fthx) wrote :

I don't agree:
1) this was working using kernel 6.3 (or maybe another software cause?)
2) this is working using Windows 11 that I have use too on my laptop
So I cannot see why no-hdmi is the right behaviour.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Can you explain what "on-demand" is and where it's set?

Changed in linux (Ubuntu):
status: Opinion → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Also are you sure it's a kernel issue and 6.3 *still* works?

I fixed a bug in mutter this week that would have previously kept the discrete GPU awake even when it wasn't being used. That was a bug though.

Revision history for this message
Francois Thirioux (fthx) wrote :

"on-demand" is the Nvidia Prime profile, it is dynamic graphics, Intel GPU is used but I can launch any app with Nvidia GPU through GNOME app's menu.
I can select dynamic graphics or discrete graphics in BIOS.

Please note that there *is* a bug since I cannot launch an app using nvidia, when using on-demand Nvidia mode. There's a demand but... ^^ I think this external monitor bug is just a sign of another bug that makes my nvidia gpu ignored by GNOME. So that's not just a matter of ports linked to nvidia gpu.

I remind this mutter bug, I was affected when my nvidia gpu was working! Thanks for that, was critical for a laptop since battery drain was very high.

I'm absolutely sure there *was* a bug with 6.5 because I remind the time where I was using both 6.3 and 6.5 in mantic, and I had to use 6.3 when I wanted to plug a monitor. But I'm absolutely *not sure* that's still the cause of this bug.

What 6.3 kernel should I test?

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Any kernel 6.3 will do, so long as you're still using libmutter >= 45.0

Revision history for this message
Francois Thirioux (fthx) wrote :

Ok I tested 6.3.13 from Ubuntu mainline ppa.
There's no "launch with dedicated gpu" app menu option, Nvidia is not listed in g-c-c system details.

So there's another point. That's why I reported another bug against GNOME Shell.
Please remind that my nvidia gpu is listed by lspci:
01:00.0 VGA compatible controller: NVIDIA Corporation GA104M [Geforce RTX 3070 Ti Laptop GPU] (rev a1)
but seems not detected by GNOME.
Remind that I see my second monitor to be not activated in gdm's login screen. I can see it activated (GNOME's dark grey) when I use nvidia-only (discrete graphics) in gdm's screen.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Oh mainline kernels probably don't support the Nvidia driver. Or perhaps just don't have the nvidia kernel driver built for them. So your GPU missing is expected in that case. I was hoping you still had the official Ubuntu kernel 6.3 installed from before the upgrade to 6.5 where nvidia was still supported...

But we still need to test older kernels so please try:

  sudo apt install --reinstall nvidia-dkms-535

to get it working on your 6.3 kernel.

Revision history for this message
Francois Thirioux (fthx) wrote :

Ok, in 6.3.13 with nvidia-535 *I get* this "launch with dedicated gpu" app menu item and both intel + nvidia gpu are listed in g-c-c system details. So I suppose hdmi is working (I did not test this).

So there's a kernel-related issue.

(Though 6.5 kernel reduce the boot time using hybrid graphics with a 100 factor vs 6.3 kernel, I remind this very annoying bug and that was because of that I tested the 6.5 kernel very early...)

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Please test HDMI with kernel 6.3.

Revision history for this message
Francois Thirioux (fthx) wrote :

HDMI works with 6.3.13.

Revision history for this message
Francois Thirioux (fthx) wrote :

Using 6.5 (hybrid graphics "on-demand" mode), I get these errors in logs:
[drm:nv_drm_load [nvidia_drm]] ERROR [nvidia-drm] [GPU ID 0x00000100] Failed to allocate NvKmsKapiDevice
[drm:nv_drm_probe_devices [nvidia_drm]] ERROR [nvidia-drm] [GPU ID 0x00000100] Failed to register device

I do not get these using 6.3. Don't know if it's related.
Again, the issue is present using Nouveau too in 6.5.

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

> Again, the issue is present using Nouveau too in 6.5.

I assume you mean the main bug here and not those log messages because 'nvidia-drm' is the proprietary driver meaning Nouveau shouldn't be loaded.

summary: - [mantic] New 6.5.0.2 kernel + Intel GPU = no HDMI
+ No HDMI in Nvidia on-demand mode
Changed in linux (Ubuntu):
status: Incomplete → New
tags: added: multimonitor nvidia
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Francois Thirioux (fthx) wrote :

Yes, the main bug is active for nvidia 535 and nouveau.

Revision history for this message
Francois Thirioux (fthx) wrote :

I tried today (dynamic graphics in bios, = on-demand) with an USB key containing the latest Mantic install and same issue.
So that's not my config/system fault.

Revision history for this message
Francois Thirioux (fthx) wrote :

If I choose:
- in BIOS: dynamic graphics (the system sees both gpus)
- in Ubuntu / Nvidia control panel /Prime profiles: perfomance mode
then I can use my system (hdmi works, launch with dedicated gpu app menu option is here).
I can see in g-c-c System details that both gpu are detected.

Revision history for this message
Francois Thirioux (fthx) wrote :

If I had to do some intuitively guess, I would think to a power management issue.
Maybe a kernel 6.4 or 6.5 pm refinement?
I know we cannot guess...

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in nvidia-graphics-drivers-535 (Ubuntu):
status: New → Confirmed
Revision history for this message
Francois Thirioux (fthx) wrote :

I tested with 6.4.16 from Ubuntu kernel PPA and I get HDMI + dGPU app launch working.

Revision history for this message
Francois Thirioux (fthx) wrote :

From same source:
6.5 rc1 does not boot (hang during boot)
6.5 rc2 does boot but does *not* have hdmi + dGPU working

Revision history for this message
Francois Thirioux (fthx) wrote :

Dynamic graphics (Intel+Nvidia), Nvidia 535 latest, Nvidia performance mode in prime
does not show two monitors connected to an usb-c dock.
I wrote here that it was working with a simple hdmi, to be confirmed.

Revision history for this message
Francois Thirioux (fthx) wrote :

6.6 rc4 does not solve the issue.

Daniel, you told me here that some error messages in Mantic's 6.5 kernel were unrelated.
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2033735/comments/39

But in (last *working* kernel) 6.4.16, I do not get these messages:

15:55:15 nvidia-settings: PRIME: is "on-demand" mode supported? yes
15:55:15 systemd: Started app-gnome-nvidia\x2dsettings-5749.scope - Application launched by gnome-shell.
15:55:11 Xorg: (II) NVIDIA(GPU-0): Deleting GPU-0
15:55:10 kernel: [drm] [nvidia-drm] [GPU ID 0x00000100] Framebuffer memory not appropriate for scanout
15:55:09 systemd: Started app-gnome-nvidia\x2dsettings\x2dautostart-4429.scope - Application launched by gnome-session-binary.
15:55:09 gnome-shell: Added device '/dev/dri/card1' (nvidia-drm) using atomic mode setting.
15:55:03 Xorg: (--) NVIDIA(GPU-0):
15:54:59 systemd: Finished systemd-backlight@backlight:nvidia_0.service - Load/Save Screen Backlight Brightness of backlight:nvidia_0.
15:54:58 nvidia-persiste: ERROR: Failed to find user ID of user 'nvidia-persistenced': Success
15:54:58 systemd: Starting nvidia-persistenced.service - NVIDIA Persistence Daemon...
15:54:57 kernel: input: HDA NVidia HDMI/DP,pcm=9 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input28
15:54:56 systemd: systemd-backlight@backlight:nvidia_0.service: Unable to break cycle starting with systemd-backlight@backlight:nvidia_0.service/start
15:54:56 kernel: nvidia-uvm: Loaded the UVM driver, major device number 509.
15:54:56 kernel: nvidia_uvm: module uses symbols nvUvmInterfaceDisableAccessCntr from proprietary module nvidia, inheriting taint.
15:54:56 kernel: [drm] Initialized nvidia-drm 0.0.0 20160202 for 0000:01:00.0 on minor 1
15:54:56 kernel: nvidia-modeset: WARNING: GPU:0: Unable to read EDID for display device DP-4
15:54:56 kernel: [drm] [nvidia-drm] [GPU ID 0x00000100] Loading driver
15:54:56 kernel: nvidia-modeset: Loading NVIDIA Kernel Mode Setting Driver for UNIX platforms 535.113.01 Tue Sep 12 19:45:42 UTC 2023
15:54:56 kernel: NVRM: loading NVIDIA UNIX x86_64 Kernel Module 535.113.01 Tue Sep 12 19:41:24 UTC 2023
15:54:56 kernel: nvidia 0000:01:00.0: vgaarb: changed VGA decodes: olddecodes=io+mem,decodes=none:owns=none
15:54:56 kernel: nvidia-nvlink: Nvlink Core is being initialized, major device number 511
15:54:56 kernel: nvidia: module license taints kernel.

Revision history for this message
konomith (konomith) wrote :

I have the exact same Lenovo model, with the same BIOS version.

Tested on Ubuntu 23.10 with kernel 6.6.6, with nvidia driver version 545.29.06 (both the proprietary and open modules), on Wayland and X, using HDMI or DP.

When "on-demand", there is no HDMI and no option to launch with dGPU. I do get the same exact messages as here https://bugs.launchpad.net/ubuntu/+source/linux/+bug/2033735/comments/39.

Revision history for this message
Francois Thirioux (fthx) wrote :

Sorry but now I use a new classical Intel-only laptop so I cannot help anymore.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.