* [PATCH v1 0/1] drm/nouveau/devinit/gf100-: fix display engine check in preinit
@ 2026-11-25 11:19 Francis Laniel
2026-11-25 11:19 ` [PATCH v1 1/1] " Francis Laniel
0 siblings, 1 reply; 2+ messages in thread
From: Francis Laniel @ 2026-11-25 11:19 UTC (permalink / raw)
To: Karol Herbst, Lyude Paul, Danilo Krummrich, David Airlie, Simona Vetter
Cc: dri-devel, nouveau, linux-kernel, 1155040, Francis Laniel
Hi,
I had a problem booting 6.12.118 kernel with NVIDIA GP108GLM [Quadro P520]:
...
[ 1.657796] nouveau 0000:2d:00.0: fb: 0 MiB GDDR5
...
[ 2.590323] BUG: unable to handle page fault for address: ffffcdd5c1400000
[ 2.590326] #PF: supervisor read access in kernel mode
[ 2.590328] #PF: error_code(0x0000) - not-present page
[ 2.590330] PGD 100000067 P4D 100000067 PUD 100203067 PMD 101f29067 PTE 0
[ 2.590334] Oops: Oops: 0000 [#1] PREEMPT SMP NOPTI
[ 2.590337] CPU: 7 UID: 0 PID: 223 Comm: (udev-worker) Not tainted 6.12.118+deb13-amd64 #1 Debian 6.12.118-1
[ 2.590340] Hardware name: LENOVO 20S4001JFR/20S4001JFR, BIOS N2XET27W (1.17 ) 12/10/2020
[ 2.590342] RIP: 0010:ioread32+0x32/0x60
[ 2.590347] Code: ff 03 00 77 25 48 81 ff 00 00 01 00 76 08 89 fa ed c3 cc cc cc cc 8b 05 6c e5 6f 01 85 c0 75 11 b8 ff ff ff ff c3 cc cc cc cc <8b> 07 e9 d7 d4 66 00 83 e8 01 48 89 fe 48 c7 c2 72 53 51 b2 48 c7
[ 2.590350] RSP: 0018:ffffcdd5c1137338 EFLAGS: 00010292
[ 2.590353] RAX: ffffffffc0a55890 RBX: ffff8aa642386c00 RCX: 0000000000000000
[ 2.590355] RDX: 00000000bad0ac3c RSI: ffffcdd5c1400000 RDI: ffffcdd5c1400000
[ 2.590357] RBP: ffffcdd5c1137374 R08: 000000000000a500 R09: 0000000000000000
[ 2.590359] R10: ffffcdd5c1380000 R11: ffffcdd5c13fffff R12: ffffcdd5c1137470
[ 2.590360] R13: ffff8aa642386cb0 R14: ffffcdd5c1137380 R15: 0000000000000000
[ 2.590362] FS: 00007fa0fa647980(0000) GS:ffff8aad4d780000(0000) knlGS:0000000000000000
[ 2.590365] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 2.590367] CR2: ffffcdd5c1400000 CR3: 000000010b472002 CR4: 00000000003706f0
[ 2.590369] Call Trace:
[ 2.590371] <TASK>
[ 2.590373] gp102_acr_wpr_patch+0xaf/0x1a0 [nouveau]
[ 2.590477] nvkm_acr_oneinit+0x3bc/0x600 [nouveau]
[ 2.590550] nvkm_subdev_oneinit_+0x42/0x90 [nouveau]
[ 2.590620] ? ktime_get+0x3a/0xd0
[ 2.590624] nvkm_subdev_init_+0x30/0xa0 [nouveau]
[ 2.590692] ? nvkm_intr_rearm+0xc7/0x1c0 [nouveau]
[ 2.590759] nvkm_subdev_init+0x48/0x60 [nouveau]
[ 2.590827] nvkm_device_init+0x16b/0x1f0 [nouveau]
[ 2.590936] nvkm_udevice_init+0x47/0x70 [nouveau]
[ 2.591044] nvkm_object_init+0x41/0x120 [nouveau]
[ 2.591115] nvkm_ioctl_new+0x160/0x220 [nouveau]
[ 2.591182] ? __pfx_nvkm_client_child_new+0x10/0x10 [nouveau]
[ 2.591249] ? __pfx_nvkm_udevice_new+0x10/0x10 [nouveau]
[ 2.593234] nvkm_ioctl+0xa6/0x140 [nouveau]
[ 2.593305] nvif_object_ctor+0x11a/0x1a0 [nouveau]
[ 2.593371] nvif_device_ctor+0x2e/0x70 [nouveau]
[ 2.593438] nouveau_drm_device_new+0x170/0x300 [nouveau]
[ 2.594065] ? __pci_set_master+0x36/0xd0
[ 2.594068] nouveau_drm_probe+0xc2/0x1e0 [nouveau]
[ 2.594167] local_pci_probe+0x42/0x90
[ 2.594171] pci_device_probe+0x25b/0x290
[ 2.594173] really_probe+0xde/0x340
[ 2.594177] ? pm_runtime_barrier+0x54/0x90
[ 2.594180] ? __pfx___driver_attach+0x10/0x10
[ 2.594182] __driver_probe_device+0x84/0x140
[ 2.594184] driver_probe_device+0x1f/0xa0
[ 2.594186] __driver_attach+0xbc/0x1d0
[ 2.594187] bus_for_each_dev+0x8c/0xe0
[ 2.594190] bus_add_driver+0x112/0x1f0
[ 2.594193] driver_register+0x72/0xd0
[ 2.594195] ? __pfx_nouveau_drm_init+0x10/0x10 [nouveau]
[ 2.594261] do_one_initcall+0x5b/0x310
[ 2.594265] do_init_module+0x60/0x230
[ 2.594269] init_module_from_file+0x89/0xe0
[ 2.594272] idempotent_init_module+0x11e/0x310
[ 2.594276] __x64_sys_finit_module+0x5e/0xb0
[ 2.594278] do_syscall_64+0x87/0x1b0
[ 2.594281] ? filemap_read+0x340/0x370
[ 2.594285] ? vfs_read+0x24d/0x370
[ 2.594288] ? __x64_sys_pread64+0x98/0xd0
[ 2.594291] ? arch_exit_to_user_mode_prepare.isra.0+0x16/0xa0
[ 2.594293] ? syscall_exit_to_user_mode+0x37/0x1b0
[ 2.594295] ? do_syscall_64+0x93/0x1b0
[ 2.594297] ? do_sys_openat2+0x9c/0xe0
[ 2.594300] ? arch_exit_to_user_mode_prepare.isra.0+0x16/0xa0
[ 2.594302] ? arch_exit_to_user_mode_prepare.isra.0+0x16/0xa0
[ 2.594304] ? syscall_exit_to_user_mode+0x37/0x1b0
[ 2.594306] ? do_syscall_64+0x93/0x1b0
[ 2.594307] ? do_syscall_64+0x93/0x1b0
[ 2.594309] ? __flush_tlb_all+0x13/0x30
[ 2.594311] ? __flush_smp_call_function_queue+0xab/0x410
[ 2.594314] ? syscall_exit_to_user_mode+0x37/0x1b0
[ 2.594316] ? clear_bhb_loop+0x70/0xc0
[ 2.594319] ? clear_bhb_loop+0x70/0xc0
[ 2.594321] entry_SYSCALL_64_after_hwframe+0x76/0x7e
[ 2.594323] RIP: 0033:0x7fa0fb1ad6b9
[ 2.594325] Code: ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 44 00 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 8b 0d 27 67 0d 00 f7 d8 64 89 01 48
[ 2.594329] RSP: 002b:00007ffc9ccb2f38 EFLAGS: 00000246 ORIG_RAX: 0000000000000139
[ 2.594332] RAX: ffffffffffffffda RBX: 000055dd07c93360 RCX: 00007fa0fb1ad6b9
[ 2.594334] RDX: 0000000000000004 RSI: 00007fa0f98d544d RDI: 000000000000001d
[ 2.594336] RBP: 0000000000000004 R08: 0000000000000000 R09: 000055dd07c6f130
[ 2.594338] R10: 0000000000000000 R11: 0000000000000246 R12: 00007fa0f98d544d
[ 2.594339] R13: 0000000000020000 R14: 000055dd07c912d0 R15: 0000000000000000
[ 2.594342] </TASK>
[ 2.594343] Modules linked in: hid_generic usbhid hid i915(+) nouveau(+) mxm_wmi drm_gpuvm drm_exec gpu_sched drm_buddy i2c_algo_bit drm_display_helper crct10dif_pclmul crc32_pclmul cec crc32c_intel ghash_clmulni_intel rc_core drm_ttm_helper sha512_ssse3 iTCO_wdt ttm sha256_ssse3 intel_pmc_bxt xhci_pci sha1_ssse3 ucsi_acpi iTCO_vendor_support xhci_hcd rtsx_pci_sdmmc watchdog aesni_intel drm_kms_helper typec_ucsi nvme mmc_core gf128mul usbcore typec nvme_core i2c_i801 psmouse drm crypto_simd roles thunderbolt e1000e video serio_raw rtsx_pci i2c_smbus nvme_auth cryptd usb_common battery wmi button
[ 2.594376] CR2: ffffcdd5c1400000
[ 2.594378] ---[ end trace 0000000000000000 ]---
With the following patch, the kernel was succesfull booting:
[ 1.404564] nouveau: loading out-of-tree module taints kernel.
[ 1.404624] nouveau: module verification failed: signature and/or required key missing - tainting kernel
[ 1.739550] nouveau: detected PR support, will not use DSM
[ 1.739571] nouveau 0000:2d:00.0: enabling device (0006 -> 0007)
[ 1.739648] nouveau 0000:2d:00.0: NVIDIA GP108 (138000a1)
[ 1.776320] nouveau 0000:2d:00.0: bios: version 86.08.3e.00.26
[ 1.776582] nouveau 0000:2d:00.0: pmu: firmware unavailable
[ 1.860292] nouveau 0000:2d:00.0: fb: 2048 MiB GDDR5
[ 1.897865] nouveau 0000:2d:00.0: drm: VRAM: 2048 MiB
[ 1.897868] nouveau 0000:2d:00.0: drm: GART: 536870912 MiB
[ 1.897869] nouveau 0000:2d:00.0: drm: BIT table 'A' not found
[ 1.897871] nouveau 0000:2d:00.0: drm: BIT table 'L' not found
[ 1.897871] nouveau 0000:2d:00.0: drm: Pointer to TMDS table not found
[ 1.902700] nouveau 0000:2d:00.0: drm: MM: using COPY for buffer copies
[ 1.902820] [drm] Initialized nouveau 1.4.0 for 0000:2d:00.0 on minor 0
[ 1.902908] nouveau 0000:2d:00.0: [drm] No compatible format found
[ 1.902910] nouveau 0000:2d:00.0: [drm] Cannot find any crtc or sizes
Basically, the patch mimics behavior existing in nv50_devinit_preinit().
Francis Laniel (1):
drm/nouveau/devinit/gf100-: fix display engine check in preinit
drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
Best regards,
--
2.47.3
^ permalink raw reply [flat|nested] 2+ messages in thread
* [PATCH v1 1/1] drm/nouveau/devinit/gf100-: fix display engine check in preinit
2026-11-25 11:19 [PATCH v1 0/1] drm/nouveau/devinit/gf100-: fix display engine check in preinit Francis Laniel
@ 2026-11-25 11:19 ` Francis Laniel
0 siblings, 0 replies; 2+ messages in thread
From: Francis Laniel @ 2026-11-25 11:19 UTC (permalink / raw)
To: Karol Herbst, Lyude Paul, Danilo Krummrich, David Airlie, Simona Vetter
Cc: dri-devel, nouveau, linux-kernel, 1155040, Francis Laniel, stable
Commit 2139cb633d48 ("drm/nouveau/devinit/gf100-: try to avoid double-running vbios scripts")
checks the return value of nvkm_devinit_disable() for the DISP engine bit.
Since commit da2b1a0a40d8 ("drm/nouveau/devinit: Convert function disable() to be void"),
that function always returns 0 and disabled engines are
removed via nvkm_subdev_disable(), which clears device->disp.
As a result the VGA CRTC heuristic is also used on display-less GPUs
(Optimus "3D controllers"), where it wrongly concludes the board was
already POSTed. Devinit is skipped and the GPU stays uninitialised,
leading to "fb: 0 MiB", PRIVRING faults and an oops in
gp102_acr_wpr_patch(), or a hang during boot.
Check device->disp instead, as nv50_devinit_preinit() does.
Fixes: 2139cb633d48 ("drm/nouveau/devinit/gf100-: try to avoid double-running vbios scripts")
Link: https://bugs.debian.org/1155040
Cc: stable@vger.kernel.org
Signed-off-by: Francis Laniel <laniel_francis@npnm.eu>
Tested-by: Francis Laniel <laniel_francis@npnm.eu>
---
drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c b/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c
index 186e09ea0cb1..b256404c2454 100644
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c
@@ -107,12 +107,12 @@ gf100_devinit_preinit(struct nvkm_devinit *base)
* VBIOS multiple times may have detrimental effects.
*/
if (base->post) {
- u64 disable = nvkm_devinit_disable(base);
+ nvkm_devinit_disable(base);
/* magic to detect whether or not x86 vbios code has
* executed the devinit scripts to initialise the
* board. only works if there's a display engine.
*/
- if (!(disable & (1ULL << NVKM_ENGINE_DISP))) {
+ if (device->disp) {
if (nvkm_rdvgac(device, 0, 0x00) ||
nvkm_rdvgac(device, 0, 0x1a)) {
base->post = false;
--
2.47.3
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-11-25 11:19 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-25 11:19 [PATCH v1 0/1] drm/nouveau/devinit/gf100-: fix display engine check in preinit Francis Laniel
2026-11-25 11:19 ` [PATCH v1 1/1] " Francis Laniel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®