[Nouveau] Nouveau dmem NULL Pointer deref (SVM)

Tobias Klausmann tobias.johannes.klausmann at mni.thm.de
Thu Mar 21 19:30:28 UTC 2019


On 21.03.19 18:12, Jerome Glisse wrote:
> On Thu, Mar 21, 2019 at 04:59:14PM +0100, Tobias Klausmann wrote:
>> Hi,
>>
>> just for your information and maybe for some help: with 5.1rc1 and SVM
>> enabled i see the following backtrace [1] when the nouveau card (reverse
>> prime) goes to sleep, for now i have papered over with [2] which leaves me
>> with userspace hangs. Any pointers where to look for the actual culprit?
>>
>> PS: Card is: nouveau 0000:01:00.0: NVIDIA GP106 (136000a1)
>>
>> Greetings,
>>
>> Tobias
> Can you check if attached patch fix the issue ?
>
> Cheers,
> Jérôme
>

Hi,

the patch is fine, you can add my R-b & Tested-by!

PS: yet i have another unrelated error keeping my card from beeing 
happy, thats now the next on my todo list:

[ 1102.004901] ------------[ cut here ]------------
[ 1102.004902] nouveau 0000:01:00.0: timeout
[ 1102.004948] WARNING: CPU: 2 PID: 55 at 
drivers/gpu/drm/nouveau/nvkm/subdev/secboot/ls_ucode_msgqueue.c:183 
acr_ls_sec2_post_run+0x139/0x190 [nouveau]
[ 1102.004949] Modules linked in: rfcomm af_packet bnep btusb uvcvideo 
btrtl btbcm rtsx_usb_sdmmc btintel videobuf2_vmalloc rtsx_usb_ms 
videobuf2_memops mmc_core bluetooth memstick videobuf2_v4l2 videodev 
videobuf2_common ecdh_generic rtsx_usb snd_hda_codec_hdmi usbhid 
snd_hda_codec_realtek snd_hda_codec_generic ledtrig_audio nouveau arc4 
nls_iso8859_1 nls_cp437 i915 vfat fat intel_rapl x86_pkg_temp_thermal 
intel_powerclamp coretemp kvm_intel ath10k_pci msr kvm ath10k_core 
snd_hda_intel irqbypass ath mxm_wmi snd_hda_codec ttm joydev mac80211 
snd_hda_core drm_kms_helper crct10dif_pclmul snd_hwdep crc32_pclmul 
snd_pcm crc32c_intel drm hid_multitouch ghash_clmulni_intel snd_timer 
hid_generic iTCO_wdt aesni_intel mei_hdcp iTCO_vendor_support snd 
aes_x86_64 fb_sys_fops cfg80211 crypto_simd acerfan syscopyarea r8169 
sysfillrect cryptd sysimgblt glue_helper realtek idma64 acer_wmi 
i2c_algo_bit mei_me libphy pcspkr sparse_keymap intel_lpss_pci 
intel_wmi_thunderbolt soundcore
[ 1102.004965]  intel_pch_thermal mei i2c_i801 intel_lpss rfkill 
wmi_bmof thermal tpm_crb tpm_tis pinctrl_sunrisepoint tpm_tis_core ac 
pinctrl_intel battery tpm button acpi_pad pcc_cpufreq xhci_pci xhci_hcd 
serio_raw usbcore i2c_hid wmi video sg dm_multipath dm_mod scsi_dh_rdac 
scsi_dh_emc scsi_dh_alua efivarfs autofs4
[ 1102.004972] CPU: 2 PID: 55 Comm: kworker/2:1 Not tainted 
5.1.0-rc1-desktop-debug+ #80
[ 1102.004973] Hardware name: Acer Aspire VN7-593G/Pluto_KLS, BIOS V1.11 
08/01/2018
[ 1102.004976] Workqueue: pm pm_runtime_work
[ 1102.005007] RIP: 0010:acr_ls_sec2_post_run+0x139/0x190 [nouveau]
[ 1102.005008] Code: 04 24 48 8b 40 10 48 8b 78 10 4c 8b 77 50 4d 85 f6 
74 1e e8 b9 2d 6a dd 48 89 c6 4c 89 f2 48 c7 c7 39 15 fb c0 e8 8c b6 20 
dd <0f> 0b e9 4c ff ff ff 4c 8b 77 10 eb dc 48 8b 04 24 48 8b 40 10 48
[ 1102.005009] RSP: 0018:ffffa45c00ee7ab8 EFLAGS: 00010296
[ 1102.005009] RAX: 000000000000001d RBX: ffff912f0e366900 RCX: 
0000000000000006
[ 1102.005010] RDX: 0000000000000007 RSI: 0000000000000086 RDI: 
ffff912f3ec963f0
[ 1102.005010] RBP: 0000000000000000 R08: 00000000000003cb R09: 
0000000000000004
[ 1102.005011] R10: 0000000000000000 R11: 0000000000000001 R12: 
ffff912f330cc400
[ 1102.005011] R13: 0000000000000040 R14: ffff912df09f0060 R15: 
ffff912df09f80b0
[ 1102.005012] FS:  0000000000000000(0000) GS:ffff912f3ec80000(0000) 
knlGS:0000000000000000
[ 1102.005012] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 1102.005013] CR2: 00007fed2968e020 CR3: 000000028a728004 CR4: 
00000000003606e0
[ 1102.005013] Call Trace:
[ 1102.005044]  acr_r352_bootstrap+0x16e/0x1d0 [nouveau]
[ 1102.005073]  acr_r352_reset+0x21/0x190 [nouveau]
[ 1102.005105]  gf100_gr_init_ctxctl_ext+0x59/0x500 [nouveau]
[ 1102.005136]  gf100_gr_init_ctxctl+0x19/0x270 [nouveau]
[ 1102.005167]  ? gf100_gr_init+0x533/0x570 [nouveau]
[ 1102.005181]  nvkm_engine_init+0xa2/0x120 [nouveau]
[ 1102.005196]  nvkm_subdev_init+0x8d/0xc0 [nouveau]
[ 1102.005226]  nvkm_device_init+0x107/0x190 [nouveau]
[ 1102.005255]  nvkm_udevice_init+0x3c/0x60 [nouveau]
[ 1102.005269]  nvkm_object_init+0x39/0x100 [nouveau]
[ 1102.005284]  nvkm_object_init+0x6c/0x100 [nouveau]
[ 1102.005299]  nvkm_object_init+0x6c/0x100 [nouveau]
[ 1102.005328]  nouveau_do_resume+0x23/0xb0 [nouveau]
[ 1102.005357]  nouveau_pmops_runtime_resume+0x7c/0x150 [nouveau]
[ 1102.005360]  ? pci_restore_standard_config+0x40/0x40
[ 1102.005361]  pci_pm_runtime_resume+0x6f/0xc0
[ 1102.005362]  ? pci_restore_standard_config+0x40/0x40
[ 1102.005363]  __rpm_callback+0x76/0x120
[ 1102.005365]  ? pci_restore_standard_config+0x40/0x40
[ 1102.005366]  rpm_callback+0x1a/0x70
[ 1102.005367]  ? pci_restore_standard_config+0x40/0x40
[ 1102.005368]  rpm_resume+0x3f5/0x5f0
[ 1102.005369]  pm_runtime_work+0x4e/0xa0
[ 1102.005370]  process_one_work+0x1d4/0x360
[ 1102.005372]  worker_thread+0x28/0x3c0
[ 1102.005372]  ? process_one_work+0x360/0x360
[ 1102.005374]  kthread+0x10d/0x130
[ 1102.005375]  ? kthread_create_worker_on_cpu+0x40/0x40
[ 1102.005377]  ret_from_fork+0x35/0x40
[ 1102.005378] ---[ end trace 7f8f178a306989b8 ]---
[ 1104.038578] nouveau 0000:01:00.0: secboot: error during falcon reset: 
-110
[ 1104.038587] nouveau 0000:01:00.0: gr: init failed, -110
[ 1104.039060] nouveau 0000:01:00.0: init failed with -110
[ 1104.039065] nouveau: X[1130]:00000000:00000080: init failed with -110
[ 1104.039068] nouveau: DRM-master:00000000:00000000: init failed with -110
[ 1104.039071] nouveau: DRM-master:00000000:00000000: init failed with -110
[ 1124.158101] nouveau 0000:01:00.0: DRM: failed to idle channel 1 [DRM]
[ 1172.454422] Asynchronous wait on fence nouveau:X[1130]:eb timed out 
(hint:submit_notify+0x0/0x58 [i915])
[ 1192.533884] nouveau 0000:01:00.0: DRM: failed to idle channel 1 [DRM]
[ 1192.533909] BUG: unable to handle kernel paging request at 
ffffa45d013d4ffc
[ 1192.533910] #PF error: [WRITE]
[ 1192.533911] PGD 107c3b067 P4D 107c3b067 PUD 0
[ 1192.533913] Oops: 0002 [#1] PREEMPT SMP PTI
[ 1192.533914] CPU: 1 PID: 54 Comm: kworker/1:1 Tainted: G W         
5.1.0-rc1-desktop-debug+ #80
[ 1192.533915] Hardware name: Acer Aspire VN7-593G/Pluto_KLS, BIOS V1.11 
08/01/2018
[ 1192.533919] Workqueue: pm pm_runtime_work
[ 1192.533988] RIP: 0010:evo_wait+0x55/0x130 [nouveau]
[ 1192.533989] Code: 00 00 00 89 c3 4c 89 f7 e8 78 dc 88 dd 89 da 44 01 
eb 48 8d 04 95 00 00 00 00 81 fb f7 03 00 00 0f 86 86 00 00 00 48 8b 45 
70 <c7> 04 90 00 00 00 20 f6 45 58 01 74 09 48 8b 7d 28 e8 d5 e1 ff ff
[ 1192.533990] RSP: 0018:ffffa45c00edfc90 EFLAGS: 00010216
[ 1192.533991] RAX: ffffa45c013d5000 RBX: 0000000040000001 RCX: 
0000000000000000
[ 1192.533992] RDX: 000000003fffffff RSI: 0000000000000002 RDI: 
ffff912f115021d0
[ 1192.533993] RBP: ffff912f11502108 R08: 0000000000000404 R09: 
ffffa45c00edfa9f
[ 1192.533994] R10: ffffa45c80ed3435 R11: 0000000000000050 R12: 
ffff912d86884350
[ 1192.533994] R13: 0000000000000002 R14: ffff912f115021d0 R15: 
0000000000000008
[ 1192.533996] FS:  0000000000000000(0000) GS:ffff912f3ec40000(0000) 
knlGS:0000000000000000
[ 1192.533996] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 1192.533997] CR2: ffffa45d013d4ffc CR3: 000000028a17e005 CR4: 
00000000003606e0
[ 1192.533998] Call Trace:
[ 1192.534045]  core507d_init+0x18/0x70 [nouveau]
[ 1192.534075]  nv50_display_init+0x2f/0xf0 [nouveau]
[ 1192.534104]  nouveau_display_init+0x26/0xb0 [nouveau]
[ 1192.534132]  nouveau_display_resume+0x1e/0x70 [nouveau]
[ 1192.534161]  nouveau_do_suspend+0x160/0x190 [nouveau]
[ 1192.534190]  nouveau_pmops_runtime_suspend+0x3d/0xa0 [nouveau]
[ 1192.534193]  pci_pm_runtime_suspend+0x56/0x140
[ 1192.534195]  ? __switch_to_asm+0x34/0x70
[ 1192.534196]  ? pci_has_legacy_pm_support+0x60/0x60
[ 1192.534198]  __rpm_callback+0x76/0x120
[ 1192.534200]  ? pci_has_legacy_pm_support+0x60/0x60
[ 1192.534201]  rpm_callback+0x1a/0x70
[ 1192.534202]  ? pci_has_legacy_pm_support+0x60/0x60
[ 1192.534203]  rpm_suspend+0xfa/0x490
[ 1192.534204]  ? __switch_to_asm+0x40/0x70
[ 1192.534205]  ? __switch_to_asm+0x34/0x70
[ 1192.534206]  ? __switch_to_asm+0x40/0x70
[ 1192.534207]  ? __switch_to_asm+0x34/0x70
[ 1192.534207]  ? __switch_to_asm+0x40/0x70
[ 1192.534209]  pm_runtime_work+0x7b/0xa0
[ 1192.534211]  process_one_work+0x1d4/0x360
[ 1192.534212]  worker_thread+0x28/0x3c0
[ 1192.534213]  ? process_one_work+0x360/0x360
[ 1192.534215]  kthread+0x10d/0x130
[ 1192.534216]  ? kthread_create_worker_on_cpu+0x40/0x40
[ 1192.534217]  ret_from_fork+0x35/0x40
[ 1192.534219] Modules linked in: rfcomm af_packet bnep btusb uvcvideo 
btrtl btbcm rtsx_usb_sdmmc btintel videobuf2_vmalloc rtsx_usb_ms 
videobuf2_memops mmc_core bluetooth memstick videobuf2_v4l2 videodev 
videobuf2_common ecdh_generic rtsx_usb snd_hda_codec_hdmi usbhid 
snd_hda_codec_realtek snd_hda_codec_generic ledtrig_audio nouveau arc4 
nls_iso8859_1 nls_cp437 i915 vfat fat intel_rapl x86_pkg_temp_thermal 
intel_powerclamp coretemp kvm_intel ath10k_pci msr kvm ath10k_core 
snd_hda_intel irqbypass ath mxm_wmi snd_hda_codec ttm joydev mac80211 
snd_hda_core drm_kms_helper crct10dif_pclmul snd_hwdep crc32_pclmul 
snd_pcm crc32c_intel drm hid_multitouch ghash_clmulni_intel snd_timer 
hid_generic iTCO_wdt aesni_intel mei_hdcp iTCO_vendor_support snd 
aes_x86_64 fb_sys_fops cfg80211 crypto_simd acerfan syscopyarea r8169 
sysfillrect cryptd sysimgblt glue_helper realtek idma64 acer_wmi 
i2c_algo_bit mei_me libphy pcspkr sparse_keymap intel_lpss_pci 
intel_wmi_thunderbolt soundcore
[ 1192.534235]  intel_pch_thermal mei i2c_i801 intel_lpss rfkill 
wmi_bmof thermal tpm_crb tpm_tis pinctrl_sunrisepoint tpm_tis_core ac 
pinctrl_intel battery tpm button acpi_pad pcc_cpufreq xhci_pci xhci_hcd 
serio_raw usbcore i2c_hid wmi video sg dm_multipath dm_mod scsi_dh_rdac 
scsi_dh_emc scsi_dh_alua efivarfs autofs4
[ 1192.534243] CR2: ffffa45d013d4ffc
[ 1192.534244] ---[ end trace 7f8f178a306989b9 ]---
[ 1192.534270] RIP: 0010:evo_wait+0x55/0x130 [nouveau]
[ 1192.534271] Code: 00 00 00 89 c3 4c 89 f7 e8 78 dc 88 dd 89 da 44 01 
eb 48 8d 04 95 00 00 00 00 81 fb f7 03 00 00 0f 86 86 00 00 00 48 8b 45 
70 <c7> 04 90 00 00 00 20 f6 45 58 01 74 09 48 8b 7d 28 e8 d5 e1 ff ff
[ 1192.534272] RSP: 0018:ffffa45c00edfc90 EFLAGS: 00010216
[ 1192.534273] RAX: ffffa45c013d5000 RBX: 0000000040000001 RCX: 
0000000000000000
[ 1192.534274] RDX: 000000003fffffff RSI: 0000000000000002 RDI: 
ffff912f115021d0
[ 1192.534275] RBP: ffff912f11502108 R08: 0000000000000404 R09: 
ffffa45c00edfa9f
[ 1192.534275] R10: ffffa45c80ed3435 R11: 0000000000000050 R12: 
ffff912d86884350
[ 1192.534276] R13: 0000000000000002 R14: ffff912f115021d0 R15: 
0000000000000008
[ 1192.534277] FS:  0000000000000000(0000) GS:ffff912f3ec40000(0000) 
knlGS:0000000000000000
[ 1192.534278] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
[ 1192.534278] CR2: ffffa45d013d4ffc CR3: 000000028a17e005 CR4: 
00000000003606e0



More information about the Nouveau mailing list