* [REGRESSION] nouveau: GM108 hangs at boot since "drm/nouveau/devinit/gf100-: try to avoid double-running vbios scripts" (6.18.64)
@ 2026-11-21 13:13 R. V. Lobato
0 siblings, 0 replies; only message in thread
From: R. V. Lobato @ 2026-11-21 13:13 UTC (permalink / raw)
To: nouveau, dri-devel, regressions
Cc: Lyude Paul, Danilo Krummrich, Dave Airlie, Ilia Mirkin, stable,
Sasha Levin, Greg Kroah-Hartman
Hi,
The 6.18.64 backport 15465d681517 ("drm/nouveau/devinit/gf100-: try
to avoid double-running vbios scripts", upstream 2139cb633d48, review
patch 426/686 <20261113153835.372076643@linuxfoundation.org>) breaks
nouveau on my GM108 laptop GPU. The machine hangs during boot.
6.18.63 works. Reverting only the gf100.c hunk of this commit on top
of 6.18.64 fixes it.
Hardware: HP Spectre x360 15-bl0XX, BIOS F.04, Intel HD 620 (i915,
drives the panel) + NVIDIA GM108M [GeForce 940MX] [10de:134d], no
display engine, runtime PM enabled.
On 6.18.64 the VRAM size is garbage and the boot stops shortly after:
nouveau 0000:01:00.0: NVIDIA GM108 (1180d0a2)
nouveau 0000:01:00.0: bios: version 82.08.62.00.15
nouveau 0000:01:00.0: fb: -1159778304 MiB GDDR5
nouveau 0000:01:00.0: bus: MMIO read of 00000000 FAULT at 6013d4 [ PRIVRING ]
nouveau 0000:01:00.0: bus: MMIO read of 00000000 FAULT at 10f65c [ PRIVRING ]
nouveau 0000:01:00.0: bus: MMIO read of 00000000 FAULT at 17e280 [ PRIVRING ]
(no "drm: VRAM", no "Initialized nouveau"; the system hangs)
On 6.18.63 the same machine prints "fb: 2048 MiB GDDR5" and nouveau
initializes normally.
My reading of the cause: the new code in gf100_devinit_preinit() runs
the VGA CRTC check only when
!(nvkm_devinit_disable(base) & (1ULL << NVKM_ENGINE_DISP))
The guard expects nvkm_devinit_disable() to return a mask of disabled
engines. In 6.18.64 it calls the void ->disable() hook, which disables
subdevs with nvkm_subdev_disable(), and then always returns 0. So the
guard is always true, also on boards without a display engine. On
GM108 the VGA CRTC reads hit the PRIVRING fault at 0x6013d4 and, I
infer, return a nonzero value (I did not log it), so post is set to
false, the VBIOS init scripts never run, and the memory controller is
left uninitialized.
nouveau.config=NvForcePost=1 lets the machine boot, but only fixes the
first init, because force_post is cleared after the first preinit.
On every runtime resume of the GPU the check skips devinit again:
[ 35.770421] nouveau 0000:01:00.0: Enabling HDA controller
[ 35.805652] nouveau 0000:01:00.0: fifo: fault 01 [WRITE] at 0000000000120000 engine 05 [BAR2] client 08 [HUB/HOST_CPU_NB] reason 02 [PTE] on channel -1 [007fd38000 unknown]
[ 35.806084] nouveau 0000:01:00.0: fifo: SCHED_ERROR 20 []
...
[ 75.453651] WARNING: CPU: 0 PID: 1081 at nvkm_runl_cgrp_get_cgid+0x79/0x110 [nouveau]
Counts per boot:
kernel runtime resumes fifo faults SCHED_ERROR WARNINGs
6.18.63 (two boots) 25 / 30 0 0 0
6.18.64 + NvForcePost=1 2 31 103381 39
6.18.64 + gf100.c hunk revert 3 0 0 0
The revert I use (restores 6.18.63's gf100.c exactly):
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/devinit/gf100.c
@@ -27,7 +27,6 @@
#include <subdev/bios/init.h>
#include <subdev/bios/pll.h>
#include <subdev/clk/pll.h>
-#include <subdev/vga.h>
int
gf100_devinit_pll_set(struct nvkm_devinit *init, u32 type, u32 freq)
@@ -100,25 +99,6 @@
* can use it as a reliable way to know whether we should run devinit.
*/
base->post = ((nvkm_rd32(device, 0x2240c) & BIT(1)) == 0);
-
- /*
- * However some VBIOS init sequences miss this bit. So fall back to
- * the nv50 method of checking if the bit is not set. Running the
- * VBIOS multiple times may have detrimental effects.
- */
- if (base->post) {
- u64 disable = 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 (nvkm_rdvgac(device, 0, 0x00) ||
- nvkm_rdvgac(device, 0, 0x1a)) {
- base->post = false;
- }
- }
- }
}
static const struct nvkm_devinit_func
A proper fix probably needs the guard to test whether the display
engine actually exists (for example nvkm_device_engine(device,
NVKM_ENGINE_DISP, 0) after ->disable() has run) instead of the return
value of nvkm_devinit_disable(). I have not tested that. I have only
tested 6.18.y; I can test patches on this machine.
#regzbot introduced: v6.18.63..v6.18.64
Thanks,
R. V. Lobato
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-21 13:14 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-21 13:13 [REGRESSION] nouveau: GM108 hangs at boot since "drm/nouveau/devinit/gf100-: try to avoid double-running vbios scripts" (6.18.64) R. V. Lobato
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.