Bug 96214 - [BAT SKL] WARN Unclaimed register detected (0x65f10) / gem_exec_suspend@basic-s4
Summary: [BAT SKL] WARN Unclaimed register detected (0x65f10) / gem_exec_suspend@basic-s4
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: DRI git
Hardware: Other All
: highest blocker
Assignee: Intel GFX Bugs mailing list
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
: 95646 (view as bug list)
Depends on:
Blocks:
 
Reported: 2016-05-25 15:36 UTC by Marius Vlad
Modified: 2016-08-26 14:07 UTC (History)
6 users (show)

See Also:
i915 platform: SKL
i915 features: display/audio


Attachments
Patch for 4.6.4 reverting the commit causing this problem. (1.62 KB, patch)
2016-07-14 12:39 UTC, Hans de Goede
no flags Details | Splinter Review
Patch for Linus' master reverting the commit causing this problem. (1.64 KB, patch)
2016-07-14 12:40 UTC, Hans de Goede
no flags Details | Splinter Review
Grab the audio powerwell for setting the registers (2.24 KB, patch)
2016-07-16 07:51 UTC, Chris Wilson
no flags Details | Splinter Review

Description Marius Vlad 2016-05-25 15:36:42 UTC
[  467.894482] [drm] GuC firmware load skipped
[  467.895388] ------------[ cut here ]------------
[  467.895417] WARNING: CPU: 0 PID: 7882 at drivers/gpu/drm/i915/intel_uncore.c:803 __unclaimed_reg_debug+0x63/0x70 [i915]
[  467.895418] Unclaimed register detected after reading register 0x65f10
[  467.895430] Modules linked in: snd_hda_intel i915 drm_kms_helper drm snd_hda_codec_hdmi snd_hda_codec_conexant snd_hda_codec_generic snd_hda_codec intel_rapl snd_hda_core xhci_pci xhci_hcd tpm_crb x86_pkg_temp_thermal intel_powerclamp i2c_hid tpm_tis tpm rtsx_pci usbcore coretemp hid snd_hwdep ghash_clmulni_intel mfd_core evdev joydev mei_me serio_raw mei snd_pcm snd_timer processor video usb_common i2c_algo_bit battery button acpi_pad ac wmi netconsole psmouse r8169 mii [last unloaded: drm]
[  467.895432] CPU: 0 PID: 7882 Comm: kworker/u16:29 Tainted: G     U          4.6.0+ #3
[  467.895432] Hardware name: TOSHIBA SATELLITE P50-C/06F4                            , BIOS 1.20 10/08/2015
[  467.895435] Workqueue: events_unbound async_run_entry_fn
[  467.895437]  0000000000000086 0000000076c67ed2 ffffffff814c4ec5 ffff880233b9fc50
[  467.895438]  0000000000000000 ffffffff810f8f0e 0000000000065f10 ffff880233b9fca8
[  467.895439]  0000000000000001 0000000000000001 0000000000000000 ffff880067610000
[  467.895439] Call Trace:
[  467.895443]  [<ffffffff814c4ec5>] ? dump_stack+0x5c/0x77
[  467.895444]  [<ffffffff810f8f0e>] ? __warn+0xbe/0xe0
[  467.895445]  [<ffffffff810f8f8f>] ? warn_slowpath_fmt+0x5f/0x80
[  467.895459]  [<ffffffffa035f4f3>] ? __unclaimed_reg_debug+0x63/0x70 [i915]
[  467.895472]  [<ffffffffa0365266>] ? gen9_read32+0x346/0x380 [i915]
[  467.895474]  [<ffffffff8150ef30>] ? pci_pm_suspend_noirq+0x170/0x170
[  467.895487]  [<ffffffffa036b8a3>] ? i915_audio_component_codec_wake_override+0x33/0xa0 [i915]
[  467.895493]  [<ffffffffa01e28d9>] ? snd_hdac_set_codec_wakeup+0x39/0x90 [snd_hda_core]
[  467.895495]  [<ffffffffa015f82a>] ? hda_intel_init_chip+0x12a/0x180 [snd_hda_intel]
[  467.895497]  [<ffffffffa01600f4>] ? azx_resume+0x94/0x160 [snd_hda_intel]
[  467.895499]  [<ffffffff815f5138>] ? dpm_run_callback+0x48/0x120
[  467.895500]  [<ffffffff815f5572>] ? device_resume+0x82/0x190
[  467.895501]  [<ffffffff815f5699>] ? async_resume+0x19/0x40
[  467.895502]  [<ffffffff81119ea5>] ? async_run_entry_fn+0x45/0x130
[  467.895503]  [<ffffffff811117ed>] ? process_one_work+0x15d/0x410
[  467.895504]  [<ffffffff81111aed>] ? worker_thread+0x4d/0x480
[  467.895505]  [<ffffffff81111aa0>] ? process_one_work+0x410/0x410
[  467.895507]  [<ffffffff8111792d>] ? kthread+0xcd/0xf0
[  467.895509]  [<ffffffff8179bf62>] ? ret_from_fork+0x22/0x40
[  467.895510]  [<ffffffff81117860>] ? kthread_create_on_node+0x190/0x190
[  467.895511] ---[ end trace 9fd67d7ca6273eba ]---


Can be reproduced each time, by running:

$ tests/gem_exec_suspend --run-subtest basic-S4

Happens after the machine returns from suspend. Assigned to Takashi as it seems to originate in snd.
Comment 1 Imre Deak 2016-05-25 15:43:14 UTC
*** Bug 95646 has been marked as a duplicate of this bug. ***
Comment 2 Takashi Iwai 2016-05-25 15:47:46 UTC
(In reply to Marius Vlad from comment #0)
> Happens after the machine returns from suspend. Assigned to Takashi as it
> seems to originate in snd.

Please ask Intel people instead.  This is a black magic SKL requires, according to the patch log, and I have no idea at all what it really matters there.
The actual code triggering it is i915_audio_component_codec_wake_override().
Comment 3 Direx 2016-05-25 16:29:11 UTC
By the way: as I mentioned in Bug 95646 this is not only related to suspend/resume, but also to power_save features.
Comment 4 Arcadiy Ivanov 2016-06-30 19:11:36 UTC
Reporting the same issue on Fedora 24, kernel 4.6.3, Dell Precision 7510.
Powertop and tlp are in use.
Comment 5 Andrzej Pronobis 2016-07-09 00:19:20 UTC
I'm seeing the same thing on Dell Precision 5510 with kernels 4.6.3 and 4.7rc6.


[  +0.178272] ------------[ cut here ]------------
[  +0.000019] WARNING: CPU: 2 PID: 13812 at drivers/gpu/drm/i915/intel_uncore.c:804 __unclaimed_reg_debug+0x63/0x70 [i915]
[  +0.000001] Unclaimed register detected after reading register 0x65f10
[  +0.000000] Modules linked in: ctr ccm cpufreq_stats uhid rfcomm vmw_vsock_vmci_transport vsock vmw_vmci uvcvideo videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_core videodev media bnep bbswitch(OE) btusb btrtl binfmt_misc nls_utf8 nls_cp437 arc4 vfat fuse nvram msr intel_rapl x86_pkg_temp_thermal intel_powerclamp fat snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic mxm_wmi dell_wmi sparse_keymap iwlmvm mac80211 kvm_intel kvm snd_hda_intel iwlwifi snd_hda_codec dell_laptop dell_smbios snd_hda_core dcdbas cfg80211 dell_smm_hwmon irqbypass snd_hwdep crct10dif_pclmul rtsx_pci_ms snd_pcm memstick crc32_pclmul ghash_clmulni_intel snd_seq_midi snd_seq_midi_event hmac snd_rawmidi drbg ansi_cprng snd_seq snd_seq_device snd_timer aesni_intel aes_x86_64 lrw snd gf128mul efi_pstore
[  +0.000023]  glue_helper hci_uart ablk_helper idma64 btbcm virt_dma ie31200_edac cryptd btqca mei_me joydev btintel intel_cstate processor_thermal_device soundcore efivars serio_raw intel_rapl_perf shpchp mei edac_core intel_soc_dts_iosf intel_lpss_pci bluetooth rfkill acpi_als int3403_thermal dell_smo8800 wmi kfifo_buf int3402_thermal intel_lpss_acpi int3400_thermal intel_lpss industrialio int340x_thermal_zone acpi_thermal_rel acpi_pad tpm_tis evdev battery ac tpm coretemp parport_pc ppdev lp parport efivarfs autofs4 ext4 crc16 jbd2 mbcache rtsx_pci_sdmmc mmc_core i915 crc32c_intel psmouse ahci libahci i2c_algo_bit xhci_pci drm_kms_helper nvme libata xhci_hcd rtsx_pci nvme_core drm usbcore scsi_mod mfd_core usb_common fan thermal i2c_hid hid video button fjes
[  +0.000023] CPU: 2 PID: 13812 Comm: tlp Tainted: G     U     OE   4.7.0-rc6-custom+ #1
[  +0.000001] Hardware name: Dell Inc. Precision 5510/08R8KJ, BIOS 01.02.10 06/30/2016
[  +0.000001]  0000000000000086 0000000084b0eaf7 ffffffff81320f35 ffff8807add67b20
[  +0.000001]  0000000000000000 ffffffff810788ae 0000000000065f10 ffff8807add67b78
[  +0.000001]  0000000000000001 0000000000000001 0000000000000000 ffff8808926c0000
[  +0.000002] Call Trace:
[  +0.000003]  [<ffffffff81320f35>] ? dump_stack+0x5c/0x77
[  +0.000002]  [<ffffffff810788ae>] ? __warn+0xbe/0xe0
[  +0.000001]  [<ffffffff8107892f>] ? warn_slowpath_fmt+0x5f/0x80
[  +0.000011]  [<ffffffffc038bd73>] ? __unclaimed_reg_debug+0x63/0x70 [i915]
[  +0.000010]  [<ffffffffc0391d56>] ? gen9_read32+0x346/0x380 [i915]
[  +0.000011]  [<ffffffffc0398163>] ? i915_audio_component_codec_wake_override+0x33/0xa0 [i915]
[  +0.000004]  [<ffffffffc0548869>] ? snd_hdac_set_codec_wakeup+0x39/0x90 [snd_hda_core]
[  +0.000002]  [<ffffffffc0658a02>] ? azx_runtime_resume+0x172/0x190 [snd_hda_intel]
[  +0.000002]  [<ffffffff8136f8a8>] ? pci_pm_runtime_resume+0x78/0xa0
[  +0.000001]  [<ffffffff814611de>] ? __rpm_callback+0x2e/0x70
[  +0.000002]  [<ffffffff8136f830>] ? pci_restore_standard_config+0x40/0x40
[  +0.000001]  [<ffffffff8146123f>] ? rpm_callback+0x1f/0x70
[  +0.000001]  [<ffffffff8136f830>] ? pci_restore_standard_config+0x40/0x40
[  +0.000001]  [<ffffffff81461c6e>] ? rpm_resume+0x48e/0x690
[  +0.000002]  [<ffffffff8120d6ea>] ? dput+0x2a/0x240
[  +0.000001]  [<ffffffff81461ac0>] ? rpm_resume+0x2e0/0x690
[  +0.000001]  [<ffffffff8146102a>] ? rpm_check_suspend_allowed+0x6a/0xb0
[  +0.000001]  [<ffffffff8146270e>] ? pm_runtime_forbid+0x3e/0x60
[  +0.000004]  [<ffffffffc084457f>] ? snd_hda_set_power_save+0x4f/0xc0 [snd_hda_codec]
[  +0.000001]  [<ffffffffc0658fab>] ? param_set_xint+0x7b/0x90 [snd_hda_intel]
[  +0.000002]  [<ffffffff8109632c>] ? param_attr_store+0x5c/0xc0
[  +0.000001]  [<ffffffff81095b2a>] ? module_attr_store+0x1a/0x30
[  +0.000002]  [<ffffffff8127178a>] ? kernfs_fop_write+0x10a/0x190
[  +0.000001]  [<ffffffff811f5a13>] ? __vfs_write+0x33/0x160
[  +0.000002]  [<ffffffff8121471e>] ? __fd_install+0x2e/0xe0
[  +0.000000]  [<ffffffff81214583>] ? __alloc_fd+0x43/0x180
[  +0.000002]  [<ffffffff81291b08>] ? security_file_permission+0x38/0xb0
[  +0.000001]  [<ffffffff811f6003>] ? vfs_write+0xb3/0x1a0
[  +0.000001]  [<ffffffff811f72c2>] ? SyS_write+0x52/0xc0
[  +0.000003]  [<ffffffff815eb976>] ? entry_SYSCALL_64_fastpath+0x1e/0xa8
[  +0.000001] ---[ end trace d51d4cafcb2f68de ]---
Comment 6 Andrzej Pronobis 2016-07-09 02:05:24 UTC
I've noticed that the problem occurs only if I boot on battery (without the AC connected) and then re-connect the AC when the system is running. 

I can also report that the patch in https://bugs.freedesktop.org/show_bug.cgi?id=95646 does not make any difference.

My audio device is:
00:1f.3 Audio device [0403]: Intel Corporation Sunrise Point-H HD Audio [8086:a170] (rev 31)
Comment 7 Chris Wilson 2016-07-10 12:27:14 UTC
Should be fixed by https://patchwork.freedesktop.org/patch/97995/
Comment 8 Hans de Goede 2016-07-12 18:53:08 UTC
(In reply to Chris Wilson from comment #7)
> Should be fixed by https://patchwork.freedesktop.org/patch/97995/

Thank you for working on this, I'm hitting this too on my skylake Dell XPS 15, I've just tried a 4.6.4 kernel with the patch applied and I'm afraid it does NOT solve the issue I'm still getting this WARN_ON:

[   32.343706] ------------[ cut here ]------------
[   32.343733] WARNING: CPU: 7 PID: 1605 at drivers/gpu/drm/i915/intel_uncore.c:649 __unclaimed_reg_debug+0x7b/0x90 [i915]
[   32.343735] Unclaimed register detected after reading register 0x65f10
[   32.343735] Modules linked in: fuse xt_CHECKSUM iptable_mangle ipt_MASQUERADE nf_nat_masquerade_ipv4 iptable_nat nf_nat_ipv4 nf_nat nf_conntrack_ipv4 nf_defrag_ipv4 xt_conntrack nf_conntrack tun bridge stp llc ebtable_filter ebtables ip6table_filter ip6_tables cpufreq_stats bnep vfat fat hid_multitouch snd_hda_codec_hdmi dell_led snd_hda_codec_realtek mei_wdt brcmfmac i2c_designware_platform snd_hda_codec_generic i2c_designware_core dell_wmi brcmutil cfg80211 intel_rapl x86_pkg_temp_thermal coretemp kvm_intel dell_laptop snd_hda_intel snd_hda_codec uvcvideo kvm dell_smbios dcdbas rtsx_pci_ms snd_hda_core snd_hwdep snd_seq memstick snd_seq_device snd_pcm irqbypass videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 snd_timer videobuf2_core joydev snd videodev i2c_i801 soundcore idma64 hci_uart btusb
[   32.343763]  mei_me btrtl btqca btbcm media mei btintel intel_lpss_pci shpchp processor_thermal_device int3403_thermal intel_soc_dts_iosf bluetooth dell_smo8800 pinctrl_sunrisepoint rfkill intel_lpss_acpi pinctrl_intel intel_lpss int3402_thermal int340x_thermal_zone intel_hid int3400_thermal acpi_als acpi_thermal_rel kfifo_buf industrialio tpm_tis sparse_keymap tpm acpi_pad binfmt_misc nouveau i915 rtsx_pci_sdmmc mmc_core crct10dif_pclmul crc32_pclmul mxm_wmi crc32c_intel i2c_algo_bit drm_kms_helper ghash_clmulni_intel ttm drm serio_raw nvme rtsx_pci nvme_core i2c_hid wmi video fjes sunrpc scsi_transport_iscsi
[   32.343785] CPU: 7 PID: 1605 Comm: pulseaudio Not tainted 4.6.4-301.bko120451.fc24.x86_64 #1
[   32.343786] Hardware name: Dell Inc. XPS 15 9550/0N7TVV, BIOS 01.02.00 04/07/2016
[   32.343787]  0000000000000086 000000000e3ed293 ffff88049813b788 ffffffff813dbcaf
[   32.343789]  ffff88049813b7d8 0000000000000000 ffff88049813b7c8 ffffffff810a742b
[   32.343791]  000002890e3ed293 0000000000000000 0000000000000001 0000000000065f10
[   32.343793] Call Trace:
[   32.343796]  [<ffffffff813dbcaf>] dump_stack+0x63/0x84
[   32.343799]  [<ffffffff810a742b>] __warn+0xcb/0xf0
[   32.343801]  [<ffffffff810a74af>] warn_slowpath_fmt+0x5f/0x80
[   32.343804]  [<ffffffff8169d838>] ? pci_conf1_write+0xb8/0xf0
[   32.343819]  [<ffffffffc0246a5b>] __unclaimed_reg_debug+0x7b/0x90 [i915]
[   32.343834]  [<ffffffffc024c4ab>] gen9_read32+0x35b/0x390 [i915]
[   32.343837]  [<ffffffff81529f6b>] ? __pm_runtime_resume+0x5b/0x70
[   32.343852]  [<ffffffffc0252ad1>] i915_audio_component_codec_wake_override+0x41/0xc0 [i915]
[   32.343857]  [<ffffffffc066ec4f>] snd_hdac_set_codec_wakeup+0x3f/0xa0 [snd_hda_core]
[   32.343860]  [<ffffffffc07eaa8f>] azx_runtime_resume+0x17f/0x190 [snd_hda_intel]
[   32.343862]  [<ffffffff8142a1cb>] pci_pm_runtime_resume+0x7b/0xa0
[   32.343863]  [<ffffffff8142a150>] ? pci_restore_standard_config+0x40/0x40
[   32.343865]  [<ffffffff81528517>] __rpm_callback+0x27/0x70
[   32.343867]  [<ffffffff8142a150>] ? pci_restore_standard_config+0x40/0x40
[   32.343869]  [<ffffffff81528584>] rpm_callback+0x24/0x80
[   32.343870]  [<ffffffff8142a150>] ? pci_restore_standard_config+0x40/0x40
[   32.343872]  [<ffffffff81528f04>] rpm_resume+0x494/0x6a0
[   32.343874]  [<ffffffff812222a5>] ? ___slab_alloc+0x295/0x520
[   32.343875]  [<ffffffff81528d46>] rpm_resume+0x2d6/0x6a0
[   32.343877]  [<ffffffff81223295>] ? __kmalloc+0x1e5/0x220
[   32.343879]  [<ffffffff81529f5e>] __pm_runtime_resume+0x4e/0x70
[   32.343882]  [<ffffffffc0668e93>] snd_hdac_power_up+0x13/0x20 [snd_hda_core]
[   32.343887]  [<ffffffffc06f59dc>] azx_pcm_open+0x1dc/0x3c0 [snd_hda_codec]
[   32.343892]  [<ffffffffc05ed47b>] snd_pcm_open_substream+0x7b/0x130 [snd_pcm]
[   32.343895]  [<ffffffffc05ed5e7>] snd_pcm_open+0xb7/0x250 [snd_pcm]
[   32.343897]  [<ffffffff81222832>] ? kmem_cache_alloc_trace+0x182/0x1d0
[   32.343900]  [<ffffffffc050d8ca>] ? snd_card_file_add+0x2a/0xd0 [snd]
[   32.343902]  [<ffffffff810d2070>] ? wake_up_q+0x70/0x70
[   32.343905]  [<ffffffffc05ed7c7>] snd_pcm_capture_open+0x47/0x70 [snd_pcm]
[   32.343908]  [<ffffffffc050d461>] snd_open+0xb1/0x180 [snd]
[   32.343910]  [<ffffffff8124de30>] chrdev_open+0xb0/0x180
[   32.343911]  [<ffffffff812466f1>] do_dentry_open+0x201/0x2e0
[   32.343913]  [<ffffffff8124dd80>] ? cdev_put+0x30/0x30
[   32.343914]  [<ffffffff81247ae4>] vfs_open+0x54/0x80
[   32.343916]  [<ffffffff81254fec>] ? may_open+0x8c/0x100
[   32.343918]  [<ffffffff81257d81>] path_openat+0x1d1/0x15b0
[   32.343920]  [<ffffffff8125a391>] do_filp_open+0x91/0x100
[   32.343922]  [<ffffffff8126771f>] ? __alloc_fd+0x3f/0x170
[   32.343924]  [<ffffffff81247ea0>] do_sys_open+0x130/0x220
[   32.343925]  [<ffffffff81247fae>] SyS_open+0x1e/0x20
[   32.343927]  [<ffffffff817e0772>] entry_SYSCALL_64_fastpath+0x1a/0xa4
[   32.343929] ---[ end trace 66ff1059d057cdec ]---
Comment 9 Chris Wilson 2016-07-12 19:56:54 UTC
So if it is not in the general GT powerwell, it must be in the display powerwell and the issue is 03b135cebc47. Does reverting that commit make rpm happy?
Comment 10 Hans de Goede 2016-07-14 12:37:27 UTC
(In reply to Chris Wilson from comment #9)
> So if it is not in the general GT powerwell, it must be in the display
> powerwell and the issue is 03b135cebc47. Does reverting that commit make rpm
> happy?

Yes that does the trick, great.

This was not a clean revert, I'll attach 2 versions of my manual revert, one for Linus' master (untested) and one for 4.6.x (tested successfully).

Feel free to pick up those reverts, set yourself as author + commiter and submit them properly.

p.s.

I'm going on vacation for weeks starting tomorrow, so I will not be responding to this bug for a while, as said feel free to take my manual revert and submit it properly.
Comment 11 Hans de Goede 2016-07-14 12:39:42 UTC
Created attachment 125065 [details] [review]
Patch for 4.6.4 reverting the commit causing this problem.
Comment 12 Hans de Goede 2016-07-14 12:40:17 UTC
Created attachment 125066 [details] [review]
Patch for Linus' master reverting the commit causing this problem.
Comment 13 yann 2016-07-15 09:24:36 UTC
Updating priority accordingly: basic test failure
Comment 14 Chris Wilson 2016-07-16 07:51:42 UTC
Created attachment 125103 [details] [review]
Grab the audio powerwell for setting the registers

It seems very fishy that we need to take the audio/display powerwell to set the registers required for HDMI audio - but at runtime it supposedly doesn't need.
Comment 15 Hans de Goede 2016-07-16 15:06:36 UTC
(In reply to Chris Wilson from comment #14)
> Created attachment 125103 [details] [review] [review]
> Grab the audio powerwell for setting the registers
> 
> It seems very fishy that we need to take the audio/display powerwell to set
> the registers required for HDMI audio - but at runtime it supposedly doesn't
> need.

I can confirm that this patch fixes the WARN_ON.
Comment 16 Ryan Owens 2016-07-16 16:14:15 UTC
My system stopped responding after this error, I had to restart. 

[  100.212613] ------------[ cut here ]------------
[  100.212668] WARNING: CPU: 2 PID: 861 at drivers/gpu/drm/i915/intel_uncore.c:649 __unclaimed_reg_debug+0x7b/0x90 [i915]
[  100.212674] Unclaimed register detected after reading register 0x65f10
[  100.212676] Modules linked in: rfcomm fuse cmac ecb sha256_ssse3 sha256_generic hmac drbg ansi_cprng ctr ccm uvcvideo videobuf2_vmalloc videobuf2_memops videobuf2_v4l2 videobuf2_core videodev media joydev mousedev btusb btrtl eeprom snd_hda_codec_hdmi nvram dell_led bnep snd_hda_codec_realtek snd_hda_codec_generic snd_soc_skl snd_soc_skl_ipc snd_soc_sst_ipc nls_iso8859_1 snd_soc_sst_dsp nls_cp437 arc4 snd_hda_ext_core snd_soc_sst_match snd_soc_core dell_laptop i2c_designware_platform vfat fat snd_compress dell_wmi i2c_designware_core snd_pcm_dmaengine dell_smbios ac97_bus dcdbas intel_rapl iwlmvm x86_pkg_temp_thermal intel_powerclamp kvm_intel mac80211 kvm irqbypass crct10dif_pclmul crc32_pclmul ghash_clmulni_intel snd_hda_intel iwlwifi snd_hda_codec dell_smm_hwmon aesni_intel aes_x86_64 lrw snd_hda_core
[  100.212781]  gf128mul glue_helper ablk_helper cryptd evdev snd_hwdep input_leds cfg80211 led_class snd_pcm i915 mac_hid psmouse serio_raw pcspkr snd_timer snd drm_kms_helper soundcore i2c_i801 drm mei_me shpchp mei idma64 intel_gtt syscopyarea sysfillrect sysimgblt processor_thermal_device fb_sys_fops intel_lpss_pci i2c_algo_bit intel_pch_thermal intel_soc_dts_iosf thermal fan wmi i2c_hid battery hci_uart int3403_thermal btbcm btqca pinctrl_sunrisepoint btintel pinctrl_intel bluetooth video dell_smo8800 int3402_thermal intel_hid int340x_thermal_zone int3400_thermal rfkill acpi_thermal_rel crc16 sparse_keymap intel_lpss_acpi intel_lpss tpm_crb tpm_tis tpm acpi_als kfifo_buf acpi_pad button ac industrialio fjes processor sch_fq_codel coretemp msr ip_tables x_tables hid_multitouch usbhid hid btrfs xor
[  100.212879]  raid6_pq sd_mod atkbd libps2 crc32c_intel ahci libahci libata xhci_pci xhci_hcd scsi_mod usbcore usb_common i8042 serio
[  100.212904] CPU: 2 PID: 861 Comm: alsa-sink-ALC32 Not tainted 4.6.4-1-ARCH #1
[  100.212907] Hardware name: Dell Inc. Inspiron 15-7569/091VKY, BIOS 01.03.00 05/26/2016
[  100.212911]  0000000000000086 00000000c07c382f ffff8800a2da37a0 ffffffff812e54c2
[  100.212919]  ffff8800a2da37f0 0000000000000000 ffff8800a2da37e0 ffffffff8107a6bb
[  100.212926]  00000289428c4e88 0000000000000000 0000000000000001 0000000000065f10
[  100.212933] Call Trace:
[  100.212945]  [<ffffffff812e54c2>] dump_stack+0x63/0x81
[  100.212951]  [<ffffffff8107a6bb>] __warn+0xcb/0xf0
[  100.212957]  [<ffffffff8107a73f>] warn_slowpath_fmt+0x5f/0x80
[  100.212966]  [<ffffffff814984a8>] ? pci_conf1_write+0xb8/0xf0
[  100.213004]  [<ffffffffa05c88eb>] __unclaimed_reg_debug+0x7b/0x90 [i915]
[  100.213036]  [<ffffffffa05c939e>] gen9_read32+0x33e/0x3b0 [i915]
[  100.213074]  [<ffffffffa05d33c9>] i915_audio_component_codec_wake_override+0x39/0xb0 [i915]
[  100.213083]  [<ffffffffa079adbf>] snd_hdac_set_codec_wakeup+0x3f/0xa0 [snd_hda_core]
[  100.213091]  [<ffffffffa0744ab3>] azx_runtime_resume+0x1a3/0x1c0 [snd_hda_intel]
[  100.213098]  [<ffffffff8132dbdb>] pci_pm_runtime_resume+0x7b/0xa0
[  100.213105]  [<ffffffff8132db60>] ? pci_restore_standard_config+0x40/0x40
[  100.213112]  [<ffffffff8141cc92>] __rpm_callback+0x32/0x70
[  100.213118]  [<ffffffff8132db60>] ? pci_restore_standard_config+0x40/0x40
[  100.213124]  [<ffffffff8141ccf4>] rpm_callback+0x24/0x80
[  100.213129]  [<ffffffff8132db60>] ? pci_restore_standard_config+0x40/0x40
[  100.213135]  [<ffffffff8141e11e>] rpm_resume+0x4be/0x6e0
[  100.213142]  [<ffffffff815c37bc>] ? schedule+0x3c/0x90
[  100.213148]  [<ffffffff8141dfca>] rpm_resume+0x36a/0x6e0
[  100.213160]  [<ffffffffa0470212>] ? snd_pcm_hw_rule_add+0x122/0x1d0 [snd_pcm]
[  100.213166]  [<ffffffff8141e37f>] __pm_runtime_resume+0x3f/0x60
[  100.213174]  [<ffffffffa0794ed3>] snd_hdac_power_up+0x13/0x20 [snd_hda_core]
[  100.213186]  [<ffffffffa087d119>] azx_pcm_open+0x1d9/0x390 [snd_hda_codec]
[  100.213197]  [<ffffffffa046f02b>] snd_pcm_open_substream+0x7b/0x130 [snd_pcm]
[  100.213206]  [<ffffffffa046f197>] snd_pcm_open+0xb7/0x250 [snd_pcm]
[  100.213215]  [<ffffffff810a3c2d>] ? ttwu_do_activate.constprop.40+0x5d/0x70
[  100.213222]  [<ffffffff810a4ac0>] ? wake_up_q+0x70/0x70
[  100.213231]  [<ffffffffa046f3e4>] snd_pcm_playback_open+0x44/0x70 [snd_pcm]
[  100.213240]  [<ffffffffa0523451>] snd_open+0xb1/0x180 [snd]
[  100.213248]  [<ffffffff811fbe10>] chrdev_open+0xb0/0x1e0
[  100.213255]  [<ffffffff811f4a11>] do_dentry_open+0x201/0x2e0
[  100.213261]  [<ffffffff811fbd60>] ? cdev_put+0x30/0x30
[  100.213268]  [<ffffffff811f5ad4>] vfs_open+0x54/0x80
[  100.213273]  [<ffffffff812026dc>] ? may_open+0x8c/0x100
[  100.213279]  [<ffffffff81205587>] path_openat+0x4e7/0x1290
[  100.213285]  [<ffffffff81207721>] do_filp_open+0x91/0x100
[  100.213293]  [<ffffffff81216cbc>] ? mntput_no_expire+0x2c/0x1b0
[  100.213299]  [<ffffffff81214679>] ? __alloc_fd+0xc9/0x180
[  100.213306]  [<ffffffff811f5ea7>] do_sys_open+0x147/0x210
[  100.213313]  [<ffffffff811f5f8e>] SyS_open+0x1e/0x20
[  100.213321]  [<ffffffff815c7232>] entry_SYSCALL_64_fastpath+0x1a/0xa4
[  100.213326] ---[ end trace 482a6891e7557d82 ]---
[  202.963842] dell_wmi: Unknown WMI event type 0x00: 0xe070
[  202.963852] dell_wmi: Unknown WMI event type 0x00: 0x0
[ 1950.707545] dell_wmi: Unknown WMI event type 0x00: 0xe070
[ 1950.707555] dell_wmi: Unknown WMI event type 0x00: 0x1
Comment 17 yann 2016-07-21 13:39:36 UTC
Ryan, did you apply Chris' patch (attachment 125103 [details] [review]) ? And can you attached also your dmesg?
Comment 18 mrummuka 2016-07-23 15:52:34 UTC
Seeing the same occurrence with Asus UC305CA / Fedora 24 kernel 4.6.4-301.fc24.x86_64 #1 SMP

--clipclip--
WARNING: CPU: 2 PID: 1863 at drivers/gpu/drm/i915/intel_uncore.c:649 __unclaimed_reg_debug+0x7b/0x90 [i915]
Unclaimed register detected after reading register 0x65f10
Modules linked in: rfcomm fuse ccm xt_CHECKSUM tun ip6t_rpfilter ip6t_REJECT nf_reject_ipv6 ipt_MASQUERADE nf_nat
iwlwifi snd_compress intel_rapl snd_pcm_dmaengine ac97_bus snd_hda_intel snd_hda_codec x86_pkg_temp_thermal asus
ghash_clmulni_intel drm serio_raw i2c_hid video fjes
CPU: 2 PID: 1863 Comm: alsa-sink-ALC25 Not tainted 4.6.4-301.fc24.x86_64 #1
Hardware name: ASUSTeK COMPUTER INC. UX305CA/UX305CA, BIOS UX305CA.300 06/08/2016
Comment 19 dog 2016-07-28 02:48:43 UTC
Bug status is NEEDINFO.  What other information is needed at this point?
Comment 20 Hans de Goede 2016-08-02 10:21:02 UTC
Hi,

What is the status of this ? I know the original reporter has not responded but I've tested the latest version of the patch on other affected hardware and I can confirm that it fixes things, can we move forward with merging this upstream please ?

The latest attached patch is:

Tested-by: Hans de Goede <hdegoede@redhat.com>

Regards,

Hans
Comment 21 Chris Wilson 2016-08-02 13:13:23 UTC
I'm not sure the patch is the right thing to do, it just swats the warn without any understanding of the underlying issue.
Comment 22 yann 2016-08-03 17:27:22 UTC
Patch is available at https://patchwork.freedesktop.org/patch/102787/

Christophe, can you re-test ?
Comment 23 cprigent 2016-08-04 11:52:09 UTC
No, I can't reproduce the bug without the patch. I tried gem_exec_suspend@basic-s4, different suspend/hibernate and runtime power management manual and IGT cases.
I also tried on a SKL-S.

Platform: NUC6i3SYB
CPU: Intel(R) Core(TM) i3-6100U CPU @ 2.30GHZ (family 6, model 78, stepping 3)
Motherboard version: H81132-502
GPU: Intel® HD Graphics 520 - Intel Corporation Sky Lake Integrated Graphics (rev 07)
Memory: one 8GB card Kingston KVR21S15D8/8
SSD: Samsung 850 EVO M.2 120 Go
Software
Bios: SYSKLi35.86A.0045.2016.0527.1055
Kernel: 4.7.0-rc7 7eeb04a from http://cgit.freedesktop.org/drm-intel/
  commit 7eeb04a101316645916d4d9df058a9341797f1af
  Author: Chris Wilson <chris@chris-wilson.co.uk>
  Date:   Sun Jul 24 11:00:31 2016 +0100
  drm-intel-nightly: 2016y-07m-24d-09h-59m-54s UTC integration manifest
drm: libdrm-2.4.70 0caa84c from git://anongit.freedesktop.org/mesa/drm
mesa: mesa-11.2.2 3a9f628from git://anongit.freedesktop.org/mesa/mesa
cairo: 1.15.2 db8a7f1 from git://anongit.freedesktop.org/cairo
xserver: xorg-server-1.18.0-497 0b2f308 from git://git.freedesktop.org/git/xorg/xserver
xf86-video-intel: 2.99.917-687 6988b87 from git://git.freedesktop.org/git/xorg/driver/xf86-video-intel
libva: libva-1.7.0-26 c36971c from git://git.freedesktop.org/git/vaapi/libva
vaapi-intel-driver: 1.7.0-58 e554446 from git://git.freedesktop.org/git/vaapi/intel-driver
DMC 1.26 from https://01.org/sites/default/files/downloads/intelr-graphics-linux/skldmcver126.tar_1.bz2
GUC 6.1 from https://01.org/sites/default/files/downloads/intelr-graphics-linux/sklgucver61.tar.bz2
Intel-Gpu-Tools 1.15-140 e3abb20 from http://anongit.freedesktop.org/git/xorg/app/intel-gpu-tools.git
Comment 24 Chris Wilson 2016-08-04 17:21:39 UTC
commit d838a110f0b310d408ebe6b5a97e36ec27555ebf
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Wed Aug 3 17:09:00 2016 +0100

    drm/i915: Acquire audio powerwell for HD-Audio registers
    
    On Haswell/Broadwell, the HD-Audio block is inside the HDMI/display
    power well and so the sna-hda audio codec acquires the display power
    well while it is operational. However, Skylake separates the powerwells
    again, but yet we still need the audio powerwell to setup the registers.
    (But then the hardware uses those registers even while powered off???)
    
    Acquiring the powerwell around setting the chicken bits when setting up
    the audio channel does at least silence the WARNs from touching our
    registers whilst unpowered. We silence our own test cases, but maybe
    there is a latent bug in using the audio channel?
    
    v2: Grab both rpm wakelock and audio wakelock
    
    Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96214
    Fixes: 03b135cebc47 "ALSA: hda - remove dependency on i915 power well for SKL")
    Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
    Cc: Libin Yang <libin.yang@intel.com>
    Cc: Takashi Iwai <tiwai@suse.de>
    Cc: Marius Vlad <marius.c.vlad@intel.com>
    Tested-by: Hans de Goede <hdegoede@redhat.com>
    Cc: stable@vger.kernel.org
    Link: http://patchwork.freedesktop.org/patch/msgid/1470240540-29004-1-git-send-email-chris@chris-wilson.co.uk
    Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

will mask this bug, but please keep your ears peeled for any glitches.
Comment 25 Dieter Stolte 2016-08-11 11:58:24 UTC
Hi,

I have an ASUS Z170-WS board and it seems that the revert patch breaks audio on my Fedora 24 system.

lspci:
00:1f.3 Audio device: Intel Corporation Sunrise Point-H HD Audio (rev 31)

Working kernel: kernel-4.6.4-301.fc24.x86_64
Not working: kernel-4.6.5-300.fc24.x86_64

Error:
kernel: snd_hda_intel 0000:00:1f.3: HSW/BDW HD-audio HDMI/DP requires binding with gfx driver.

Change which seems to be the problem:
Revert-ALSA-hda-remove-controller-dependency-on-i915.patch
Comment 26 Hans de Goede 2016-08-11 12:22:47 UTC
Hi,

(In reply to Dieter Stolte from comment #25)
> Hi,
> 
> I have an ASUS Z170-WS board and it seems that the revert patch breaks audio
> on my Fedora 24 system.
> 
> lspci:
> 00:1f.3 Audio device: Intel Corporation Sunrise Point-H HD Audio (rev 31)
> 
> Working kernel: kernel-4.6.4-301.fc24.x86_64
> Not working: kernel-4.6.5-300.fc24.x86_64
> 
> Error:
> kernel: snd_hda_intel 0000:00:1f.3: HSW/BDW HD-audio HDMI/DP requires
> binding with gfx driver.
> 
> Change which seems to be the problem:
> Revert-ALSA-hda-remove-controller-dependency-on-i915.patch

Thanks for reporting this, I've already replaced that patch with Chris Wilson's patch in current Fedora kernel pkg git, so this should be fixed by the next Fedora kernel build (when that shows up).

Regards,

Hans


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.