Skip to contentSkip to conversation

snd/hda: Flush interrupts on disabling

PATCH New Chris Wilson 2 participants 4 messages Jul 20, 2019 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 snd/hda: Flush interrupts on disabling

I was looking at

<4> [241.835158] general protection fault: 0000 [#1] PREEMPT SMP PTI
<4> [241.835181] CPU: 1 PID: 214 Comm: kworker/1:3 Tainted: G U 5.2.0-CI-CI_DRM_6509+ #1
<4> [241.835199] Hardware name: Dell Inc. OptiPlex 745 /0GW726, BIOS 2.3.1 05/21/2007
<4> [241.835234] Workqueue: events snd_hdac_bus_process_unsol_events [snd_hda_core]
<4> [241.835256] RIP: 0010:input_handle_event+0x16d/0x5e0
<4> [241.835270] Code: 48 8b 93 58 01 00 00 8b 52 08 89 50 04 8b 83 f8 06 00 00 48 8b 93 00 07 00 00 8d 70 01 48 8d 04 c2 83 e1 08 89 b3 f8 06 00 00 <66> 89 28 66 44 89 60 02 44 89 68 04 8b 93 f8 06 00 00 0f 84 fd fe <4> [241.835304] RSP: 0018:ffffc9000019fda0 EFLAGS: 00010046
<4> [241.835317] RAX: 6b6b6b6ec6c6c6c3 RBX: ffff8880290fefc8 RCX: 0000000000000000
<4> [241.835332] RDX: 000000006b6b6b6b RSI: 000000006b6b6b6c RDI: 0000000000000046
<4> [241.835347] RBP: 0000000000000005 R08: 0000000000000000 R09: 0000000000000001
<4> [241.835362] R10: ffffc9000019faa0 R11: 0000000000000000 R12: 0000000000000004
<4> [241.835377] R13: 0000000000000000 R14: ffff8880290ff1d0 R15: 0000000000000293
<4> [241.835392] FS: 0000000000000000(0000) GS:ffff88803de80000(0000) knlGS:0000000000000000
<4> [241.835409] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
<4> [241.835422] CR2: 00007ffe9a99e9b7 CR3: 000000002f588000 CR4: 00000000000006e0
<4> [241.835436] Call Trace:

<4> [241.835449]  input_event+0x45/0x70
<4> [241.835464]  snd_jack_report+0xdc/0x100
<4> [241.835490]  snd_hda_jack_report_sync+0x83/0xc0 [snd_hda_codec]
<4> [241.835512]  snd_hdac_bus_process_unsol_events+0x5a/0x70 [snd_hda_core]
<4> [241.835530]  process_one_work+0x245/0x610

which has the hallmarks of a worker queued from interrupt after it was supposedly cancelled (note the POISON_FREE), and I could not see where the interrupt would be flushed on shutdown so added the likely suspects.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=111174

Cc Takashi Iwai <[email protected]>
Cc Jaroslav Kysela <[email protected]>
---
 sound/hda/hdac_controller.c | 2 ++
 sound/pci/hda/hda_intel.c   | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)
sound/hda/hdac_controller.c +2 -0
index 3b0110545070..196bbc85699e 100644
@@ -447,6 +447,8 @@ static void azx_int_disable(struct hdac_bus *bus)
 	list_for_each_entry(azx_dev, &bus->stream_list, list)
 		snd_hdac_stream_updateb(azx_dev, SD_CTL, SD_INT_MASK, 0);
 
+	synchronize_irq(bus->irq);
+
 	/* disable SIE for all streams */
 	snd_hdac_chip_writeb(bus, INTCTL, 0);
 
sound/pci/hda/hda_intel.c +1 -1
index cb8b0945547c..fdde80d95966 100644
@@ -1301,9 +1301,9 @@ static int azx_free(struct azx *chip)
 	}
 
 	if (bus->chip_init) {
+		azx_stop_chip(chip);
 		azx_clear_irq_pending(chip);
 		azx_stop_all_streams(chip);
-		azx_stop_chip(chip);
 	}
 
 	if (bus->irq >= 0)
Signature · 6 lines
2.22.0

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
#1 lore raw

✗ Fi.CI.CHECKPATCH: warning for snd/hda: Flush interrupts on disabling

== Series Details ==

== Series Details ==

Series: snd/hda: Flush interrupts on disabling
URL : https://patchwork.freedesktop.org/series/63960/
State : warning

== Summary ==

$ dim checkpatch origin/drm-tip
b09cb7a25585 snd/hda: Flush interrupts on disabling
-:9: WARNING:COMMIT_LOG_LONG_LINE: Possible unwrapped commit description (prefer a maximum 75 chars per line)
#9: 
<4> [241.835181] CPU: 1 PID: 214 Comm: kworker/1:3 Tainted: G     U            5.2.0-CI-CI_DRM_6509+ #1

total: 0 errors, 1 warnings, 0 checks, 18 lines checked

_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#2 lore raw

✓ Fi.CI.BAT: success for snd/hda: Flush interrupts on disabling

In reply to Chris Wilson
== Series Details ==

== Series Details ==

Series: snd/hda: Flush interrupts on disabling
URL : https://patchwork.freedesktop.org/series/63960/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_6515 -> Patchwork_13709
====================================================

Summary
-------

**SUCCESS**

No regressions found.

External URL: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/

Known issues
------------

Here are the changes found in Patchwork_13709 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@i915_pm_rpm@module-reload:
- fi-skl-6770hq: [PASS][1] -> [DMESG-WARN][2] ([fdo#105541])
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-skl-6770hq/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-skl-6770hq/igt@[email protected]

* igt@i915_selftest@live_execlists:
- fi-skl-gvtdvm: [PASS][3] -> [DMESG-FAIL][4] ([fdo#111108])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-skl-gvtdvm/igt@i915_selftest@live_execlists.html
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-skl-gvtdvm/igt@i915_selftest@live_execlists.html

* igt@kms_busy@basic-flip-c:
- fi-skl-6770hq: [PASS][5] -> [SKIP][6] ([fdo#109271] / [fdo#109278]) +2 similar issues
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-skl-6770hq/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-skl-6770hq/igt@[email protected]
- fi-icl-dsi: [PASS][7] -> [DMESG-WARN][8] ([fdo#106107])
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-icl-dsi/igt@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-icl-dsi/igt@[email protected]

* igt@kms_flip@basic-flip-vs-dpms:
- fi-skl-6770hq: [PASS][9] -> [SKIP][10] ([fdo#109271]) +23 similar issues
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-skl-6770hq/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-skl-6770hq/igt@[email protected]

#### Possible fixes ####

* igt@gem_exec_suspend@basic-s3:
- fi-blb-e6850: [INCOMPLETE][11] ([fdo#107718]) -> [PASS][12]
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-blb-e6850/igt@[email protected]
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-blb-e6850/igt@[email protected]

* igt@i915_selftest@live_contexts:
- fi-skl-iommu: [INCOMPLETE][13] ([fdo#111050]) -> [PASS][14]
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/fi-skl-iommu/igt@i915_selftest@live_contexts.html
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/fi-skl-iommu/igt@i915_selftest@live_contexts.html

[fdo#105541]: https://bugs.freedesktop.org/show_bug.cgi?id=105541
[fdo#106107]: https://bugs.freedesktop.org/show_bug.cgi?id=106107
[fdo#107718]: https://bugs.freedesktop.org/show_bug.cgi?id=107718
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109278]: https://bugs.freedesktop.org/show_bug.cgi?id=109278
[fdo#111050]: https://bugs.freedesktop.org/show_bug.cgi?id=111050
[fdo#111108]: https://bugs.freedesktop.org/show_bug.cgi?id=111108

Participating hosts (53 -> 43)
------------------------------

Missing (10): fi-kbl-soraka fi-cml-u2 fi-icl-u4 fi-byt-squawks fi-bsw-cyan fi-icl-u3 fi-icl-y fi-icl-guc fi-byt-clapper fi-bdw-samus

Build changes
-------------

* Linux: CI_DRM_6515 -> Patchwork_13709

CI_DRM_6515: a9fbb0055257ca5040e81c155212609c1bd6dc0e @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5104: 10288a94dccead63efbd59d872c8c4ce9cf19788 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_13709: b09cb7a255855e96e376ef368bd97a4f1f8912f8 @ git://anongit.freedesktop.org/gfx-ci/linux

== Linux commits ==

b09cb7a25585 snd/hda: Flush interrupts on disabling

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#3 lore raw

✓ Fi.CI.IGT: success for snd/hda: Flush interrupts on disabling

In reply to Chris Wilson
== Series Details ==

== Series Details ==

Series: snd/hda: Flush interrupts on disabling
URL : https://patchwork.freedesktop.org/series/63960/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_6515_full -> Patchwork_13709_full
====================================================

Summary
-------

**SUCCESS**

No regressions found.

Known issues
------------

Here are the changes found in Patchwork_13709_full that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@gem_ctx_isolation@rcs0-s3:
- shard-apl: [PASS][1] -> [DMESG-WARN][2] ([fdo#108566]) +3 similar issues
[1]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-apl1/igt@[email protected]
[2]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-apl6/igt@[email protected]

* igt@gem_exec_balancer@smoke:
- shard-iclb: [PASS][3] -> [SKIP][4] ([fdo#110854])
[3]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb2/igt@[email protected]
[4]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb7/igt@[email protected]

* igt@gem_tiled_swapping@non-threaded:
- shard-glk: [PASS][5] -> [DMESG-WARN][6] ([fdo#108686])
[5]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-glk3/igt@[email protected]
[6]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-glk7/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbc-1p-pri-indfb-multidraw:
- shard-iclb: [PASS][7] -> [FAIL][8] ([fdo#103167]) +6 similar issues
[7]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb7/igt@[email protected]
[8]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb6/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbc-suspend:
- shard-skl: [PASS][9] -> [INCOMPLETE][10] ([fdo#104108]) +1 similar issue
[9]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-skl4/igt@[email protected]
[10]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-skl3/igt@[email protected]

* igt@kms_psr@psr2_cursor_render:
- shard-iclb: [PASS][11] -> [SKIP][12] ([fdo#109441]) +1 similar issue
[11]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb2/igt@kms_psr@psr2_cursor_render.html
[12]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb5/igt@kms_psr@psr2_cursor_render.html

* igt@kms_setmode@basic:
- shard-skl: [PASS][13] -> [FAIL][14] ([fdo#99912])
[13]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-skl8/igt@[email protected]
[14]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-skl8/igt@[email protected]

#### Possible fixes ####

* igt@gem_softpin@noreloc-s3:
- shard-apl: [DMESG-WARN][15] ([fdo#108566]) -> [PASS][16] +1 similar issue
[15]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-apl2/igt@[email protected]
[16]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-apl7/igt@[email protected]

* igt@kms_draw_crc@draw-method-xrgb8888-blt-xtiled:
- shard-skl: [FAIL][17] ([fdo#103184] / [fdo#103232]) -> [PASS][18]
[17]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-skl3/igt@[email protected]
[18]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-skl7/igt@[email protected]

* igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-shrfb-draw-pwrite:
- shard-iclb: [FAIL][19] ([fdo#103167]) -> [PASS][20] +3 similar issues
[19]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb1/igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-shrfb-draw-pwrite.html
[20]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb4/igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-shrfb-draw-pwrite.html

* igt@kms_plane_alpha_blend@pipe-c-coverage-7efc:
- shard-skl: [FAIL][21] ([fdo#108145] / [fdo#110403]) -> [PASS][22]
[21]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-skl9/igt@[email protected]
[22]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-skl6/igt@[email protected]

* igt@kms_psr@psr2_sprite_mmap_gtt:
- shard-iclb: [SKIP][23] ([fdo#109441]) -> [PASS][24] +3 similar issues
[23]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb7/igt@kms_psr@psr2_sprite_mmap_gtt.html
[24]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb2/igt@kms_psr@psr2_sprite_mmap_gtt.html

* igt@perf@blocking:
- shard-skl: [FAIL][25] ([fdo#110728]) -> [PASS][26]
[25]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-skl5/igt@[email protected]
[26]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-skl3/igt@[email protected]

#### Warnings ####

* igt@kms_dp_dsc@basic-dsc-enable-edp:
- shard-iclb: [SKIP][27] ([fdo#109349]) -> [DMESG-WARN][28] ([fdo#107724])
[27]: https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_6515/shard-iclb7/igt@[email protected]
[28]: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/shard-iclb2/igt@[email protected]

[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#103184]: https://bugs.freedesktop.org/show_bug.cgi?id=103184
[fdo#103232]: https://bugs.freedesktop.org/show_bug.cgi?id=103232
[fdo#104108]: https://bugs.freedesktop.org/show_bug.cgi?id=104108
[fdo#107724]: https://bugs.freedesktop.org/show_bug.cgi?id=107724
[fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
[fdo#108566]: https://bugs.freedesktop.org/show_bug.cgi?id=108566
[fdo#108686]: https://bugs.freedesktop.org/show_bug.cgi?id=108686
[fdo#109349]: https://bugs.freedesktop.org/show_bug.cgi?id=109349
[fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
[fdo#110403]: https://bugs.freedesktop.org/show_bug.cgi?id=110403
[fdo#110728]: https://bugs.freedesktop.org/show_bug.cgi?id=110728
[fdo#110854]: https://bugs.freedesktop.org/show_bug.cgi?id=110854
[fdo#99912]: https://bugs.freedesktop.org/show_bug.cgi?id=99912

Participating hosts (10 -> 10)
------------------------------

No changes in participating hosts

Build changes
-------------

* Linux: CI_DRM_6515 -> Patchwork_13709

CI_DRM_6515: a9fbb0055257ca5040e81c155212609c1bd6dc0e @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_5104: 10288a94dccead63efbd59d872c8c4ce9cf19788 @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_13709: b09cb7a255855e96e376ef368bd97a4f1f8912f8 @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_13709/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx