drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
Subsystems (2)
PATCH 1/1 drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
From: Ville Syrjälä <[email protected]>
PIPESTAT registers live in the display power well on VLV/CHV, so we shouldn't access them when things are powered down. Let's check whether the display interrupts are on or off before accessing the PIPESTAT registers.
Another option would be to read the PIPESTAT registers only when the IIR register indicates that there's a pending pipe event. But that would mean we might miss even more underrun reports than we do now, because the underrun status bit lives in PIPESTAT but doesn't actually generate an interrupt.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93738
--- drivers/gpu/drm/i915/i915_irq.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/gpu/drm/i915/i915_irq.c +6 -0
@@ -1651,6 +1651,12 @@ static void valleyview_pipestat_irq_handler(struct drm_device *dev, u32 iir)int pipe;spin_lock (&dev_priv->irq_lock); + +if (!dev_priv->display_irqs_enabled) { +spin_unlock (&dev_priv->irq_lock); +return ; + } +for_each_pipe (dev_priv, pipe) {i915_reg_t reg;u32 mask, iir_bit =0 ;
Signature · 6 lines
2.4.10 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✗ Fi.CI.BAT: failure for drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
== Summary ==
== Summary ==
Series 3599v1 drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
http://patchwork.freedesktop.org/api/1.0/series/3599/revisions/1/mbox/
Test core_auth:
Subgroup basic-auth:
pass -> INCOMPLETE (ilk-hp8440p)
Test core_prop_blob:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test drv_getparams_basic:
Subgroup basic-subslice-total:
pass -> INCOMPLETE (ilk-hp8440p)
Test drv_module_reload_basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_basic:
Subgroup bad-close:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup create-close:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_cpu_reloc:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_cs_prefetch:
Subgroup basic-default:
incomplete -> PASS (ilk-hp8440p)
Test gem_cs_tlb:
Subgroup basic-default:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_ctx_create:
Subgroup basic:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_ctx_exec:
Subgroup basic:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_ctx_param_basic:
Subgroup basic:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup invalid-ctx-set:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup invalid-param-get:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup non-root-set:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup non-root-set-no-zeromap:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup root-set-no-zeromap-enabled:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_exec_basic:
Subgroup basic-blt:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-bsd:
pass -> INCOMPLETE (ilk-hp8440p)
pass -> INCOMPLETE (ivb-t430s)
Subgroup basic-bsd1:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-bsd2:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_exec_parse:
Subgroup basic-rejected:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_flink_basic:
Subgroup bad-flink:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bad-open:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup double-flink:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_mmap:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-small-bo:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_mmap_gtt:
Subgroup basic-copy:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-read-no-prefault:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-small-bo:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-small-bo-tiledx:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-small-copy:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-small-copy-xy:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-write-cpu-read-gtt:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-write-no-prefault:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-write-read:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-write-read-distinct:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_pread:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_pwrite:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_ringfill:
Subgroup basic-default-bomb:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-default-forked:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_storedw_loop:
Subgroup basic-bsd:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-bsd1:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-bsd2:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-vebox:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_sync:
Subgroup basic-blt:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-bsd2:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-default:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-render:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-vebox:
skip -> INCOMPLETE (ilk-hp8440p)
Test gem_tiled_blits:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test gem_tiled_fence_blits:
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Test kms_addfb_basic:
Subgroup addfb25-bad-modifier:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup addfb25-framebuffer-vs-set-tiling:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup addfb25-y-tiled:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup addfb25-y-tiled-small:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup bad-pitch-0:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bad-pitch-128:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bad-pitch-63:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bad-pitch-999:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-x-tiled:
pass -> INCOMPLETE (ivb-t430s)
Subgroup basic-y-tiled:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bo-too-small:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup bo-too-small-due-to-tiling:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup clobberred-modifier:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup no-handle:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup size-max:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup small-bo:
pass -> INCOMPLETE (ilk-hp8440p)
pass -> INCOMPLETE (ivb-t430s)
Subgroup too-high:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup too-wide:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup unused-modifier:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup unused-offsets:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup unused-pitches:
pass -> INCOMPLETE (ilk-hp8440p)
Test kms_flip:
Subgroup basic-flip-vs-dpms:
pass -> DMESG-WARN (ilk-hp8440p) UNSTABLE
Subgroup basic-flip-vs-wf_vblank:
pass -> INCOMPLETE (ilk-hp8440p) UNSTABLE
Subgroup basic-plain-flip:
pass -> INCOMPLETE (ilk-hp8440p)
Test kms_force_connector_basic:
Subgroup force-connector-state:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup force-edid:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup force-load-detect:
dmesg-fail -> FAIL (snb-dellxps)
fail -> INCOMPLETE (ilk-hp8440p)
Subgroup prune-stale-modes:
pass -> INCOMPLETE (ilk-hp8440p)
Test kms_pipe_crc_basic:
Subgroup bad-source:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup hang-read-crc-pipe-a:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup nonblocking-crc-pipe-a-frame-sequence:
pass -> INCOMPLETE (ilk-hp8440p)
pass -> INCOMPLETE (ivb-t430s)
Subgroup nonblocking-crc-pipe-b:
pass -> INCOMPLETE (ivb-t430s)
Subgroup nonblocking-crc-pipe-b-frame-sequence:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup nonblocking-crc-pipe-c:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup nonblocking-crc-pipe-c-frame-sequence:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup read-crc-pipe-a-frame-sequence:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup read-crc-pipe-b:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup read-crc-pipe-c-frame-sequence:
skip -> INCOMPLETE (ilk-hp8440p)
Subgroup suspend-read-crc-pipe-a:
pass -> DMESG-WARN (skl-i5k-2) UNSTABLE
dmesg-warn -> PASS (skl-i7k-2) UNSTABLE
pass -> INCOMPLETE (ilk-hp8440p)
pass -> DMESG-WARN (ivb-t430s)
Subgroup suspend-read-crc-pipe-b:
pass -> DMESG-WARN (skl-i7k-2) UNSTABLE
Subgroup suspend-read-crc-pipe-c:
dmesg-warn -> PASS (skl-i5k-2) UNSTABLE
skip -> INCOMPLETE (ilk-hp8440p)
Test kms_setmode:
Subgroup basic-clone-single-crtc:
pass -> DMESG-WARN (bsw-nuc-2)
pass -> INCOMPLETE (ilk-hp8440p)
Test pm_backlight:
Subgroup basic-brightness:
pass -> INCOMPLETE (ilk-hp8440p)
Test pm_rpm:
Subgroup basic-rte:
dmesg-warn -> PASS (bsw-nuc-2)
Test prime_self_import:
Subgroup basic-llseek-bad:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-llseek-size:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-with_fd_dup:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-with_one_bo:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-with_one_bo_two_files:
pass -> INCOMPLETE (ilk-hp8440p)
Subgroup basic-with_two_bos:
pass -> INCOMPLETE (ilk-hp8440p)
pass -> INCOMPLETE (ivb-t430s)bdw-nuci7 total:164 pass:153 dwarn:0 dfail:0 fail:0 skip:11 bsw-nuc-2 total:167 pass:136 dwarn:1 dfail:0 fail:0 skip:30 byt-nuc total:167 pass:141 dwarn:1 dfail:0 fail:0 skip:25 hsw-gt2 total:167 pass:156 dwarn:0 dfail:1 fail:0 skip:10 ilk-hp8440p total:167 pass:45 dwarn:1 dfail:0 fail:0 skip:23 ivb-t430s total:167 pass:143 dwarn:1 dfail:0 fail:1 skip:13 skl-i5k-2 total:167 pass:150 dwarn:1 dfail:0 fail:0 skip:16 skl-i7k-2 total:167 pass:150 dwarn:1 dfail:0 fail:0 skip:16 snb-dellxps total:167 pass:144 dwarn:0 dfail:0 fail:1 skip:22
Results at /archive/results/CI_IGT_test/Patchwork_1439/
e4599905334de9349501a383afb8503a1dde5728 drm-intel-nightly: 2016y-02m-18d-17h-13m-22s UTC integration manifest 2bd1d6398414b9fd5b85cfd9f8f90d65938d7d1c drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: ✗ Fi.CI.BAT: failure for drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
Quoted 11 lines · Patchwork
== Summary ==
Series 3599v1 drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
http://patchwork.freedesktop.org/api/1.0/series/3599/revisions/1/mbox/Test
core_auth:Subgroup basic-auth: pass -> INCOMPLETE (ilk-hp8440p) Test core_prop_blob: Subgroup basic: pass -> INCOMPLETE (ilk-hp8440p)
The ilk seems very unahppy lately. Not sure if this is just some igt/piglit/etc. change that broke things or if we really managed to break the driver.
It looks like this mess started from CI_DRM_1077, so I tried to dig out the kernel shas for CI_DRM_1076 and CI_DRM_1077. Assuming I looked in the right place the diff consists of two parts:dd75619853e4 ("drm/i915: Extract intel_encoder_has_connectors()") 67ec1072b053 ("ALSA: pcm: Fix rwsem deadlock for non-atomic PCM
I can't convince myself that there's anything wrong with my intel_encoder_has_connectors(), so it's either the sound locking stuff (which also feels a bit unlikely to me), or just totally unrelated to the kernel.
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Re: ✗ Fi.CI.BAT: failure for drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
In reply to PatchworkQuoted 7 lines · Patchwork
== Summary ==
Series 3599v1 drm/i915: Skip PIPESTAT reads from irq handler on VLV/CHV when power well is down
http://patchwork.freedesktop.org/api/1.0/series/3599/revisions/1/mbox/Subgroup force-load-detect: dmesg-fail -> FAIL (snb-dellxps)
Maarten's stuff.
Quoted 3 lines
Subgroup suspend-read-crc-pipe-a:
pass -> DMESG-WARN (skl-i5k-2) UNSTABLE
dmesg-warn -> PASS (skl-i7k-2) UNSTABLEintel_pstate vs. cpu_hotplug lockdep
Quoted 1 line
pass -> DMESG-WARN (ivb-t430s)
[ 469.446868] [drm:intel_set_cpu_fifo_underrun_reporting [i915]] *ERROR* uncleared fifo underrun on pipe B
Not sure what to make of that. I do know our wm code is in a bad state right now and tends to cause underruns whenever we turn a plane on or off.
Quoted 4 lines
Subgroup suspend-read-crc-pipe-b:
pass -> DMESG-WARN (skl-i7k-2) UNSTABLE
Subgroup suspend-read-crc-pipe-c:
dmesg-warn -> PASS (skl-i5k-2) UNSTABLEintel_pstate vs. cpu_hotplug lockdep
Quoted 3 lines
Test
kms_setmode:Subgroup basic-clone-single-crtc: pass -> DMESG-WARN (bsw-nuc-2)
lockdep wasn't happy:
[ 82.811702] ======================================================
[ 82.811705] [ INFO: possible circular locking dependency detected ]
[ 82.811709] 4.5.0-rc4-gfxbench+ #1 Not tainted
[ 82.811711] -------------------------------------------------------
[ 82.811714] kms_setmode/5859 is trying to acquire lock:
[ 82.811717] (&dev->struct_mutex){+.+.+.}, at: [<ffffffff8150d9c1>] drm_gem_mmap+0x1a1/0x270
[ 82.811731]
but task is already holding lock:
[ 82.811734] (&mm->mmap_sem){++++++}, at: [<ffffffff8117b364>] vm_mmap_pgoff+0x44/0xa0
[ 82.811745] which lock already depends on the new lock.
[ 82.811749]
the existing dependency chain (in reverse order) is:
[ 82.811752]
-> #3 (&mm->mmap_sem){++++++}:
[ 82.811761] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0
[ 82.811766] [<ffffffff8118bc65>] __might_fault+0x75/0xa0
[ 82.811771] [<ffffffff8124da4a>] kernfs_fop_write+0x8a/0x180
[ 82.811787] [<ffffffff811d1023>] __vfs_write+0x23/0xe0
[ 82.811792] [<ffffffff811d1d74>] vfs_write+0xa4/0x190
[ 82.811797] [<ffffffff811d2c14>] SyS_write+0x44/0xb0
[ 82.811801] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73
[ 82.811807]
-> #2 (s_active#6){++++.+}:
[ 82.811814] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0
[ 82.811819] [<ffffffff8124c070>] __kernfs_remove+0x210/0x2f0
[ 82.811823] [<ffffffff8124d040>] kernfs_remove_by_name_ns+0x40/0xa0
[ 82.811828] [<ffffffff8124e9e0>] sysfs_remove_file_ns+0x10/0x20
[ 82.811832] [<ffffffff815318d4>] device_del+0x124/0x250
[ 82.811837] [<ffffffff81531a19>] device_unregister+0x19/0x60
[ 82.811841] [<ffffffff8153c051>] cpu_cache_sysfs_exit+0x51/0xb0
[ 82.811846] [<ffffffff8153c628>] cacheinfo_cpu_callback+0x38/0x70
[ 82.811851] [<ffffffff8109ae89>] notifier_call_chain+0x39/0xa0
[ 82.811856] [<ffffffff8109aef9>] __raw_notifier_call_chain+0x9/0x10
[ 82.811860] [<ffffffff810786de>] cpu_notify+0x1e/0x40
[ 82.811865] [<ffffffff81078779>] cpu_notify_nofail+0x9/0x20
[ 82.811869] [<ffffffff81078ac3>] _cpu_down+0x233/0x340
[ 82.811874] [<ffffffff81079019>] disable_nonboot_cpus+0xc9/0x350
[ 82.811878] [<ffffffff810d2e11>] suspend_devices_and_enter+0x5a1/0xb50
[ 82.811883] [<ffffffff810d3903>] pm_suspend+0x543/0x8d0
[ 82.811888] [<ffffffff810d1b77>] state_store+0x77/0xe0
[ 82.811892] [<ffffffff813fa68f>] kobj_attr_store+0xf/0x20
[ 82.811897] [<ffffffff8124e740>] sysfs_kf_write+0x40/0x50
[ 82.811902] [<ffffffff8124dafc>] kernfs_fop_write+0x13c/0x180
[ 82.811906] [<ffffffff811d1023>] __vfs_write+0x23/0xe0
[ 82.811910] [<ffffffff811d1d74>] vfs_write+0xa4/0x190
[ 82.811914] [<ffffffff811d2c14>] SyS_write+0x44/0xb0
[ 82.811918] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73
[ 82.811923]
-> #1 (cpu_hotplug.lock){+.+.+.}:
[ 82.811929] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0
[ 82.811933] [<ffffffff817b6f72>] mutex_lock_nested+0x62/0x3b0
[ 82.811940] [<ffffffff810784c1>] get_online_cpus+0x61/0x80
[ 82.811944] [<ffffffff811170eb>] stop_machine+0x1b/0xe0
[ 82.811949] [<ffffffffa0178edd>] gen8_ggtt_insert_entries__BKL+0x2d/0x30 [i915]
[ 82.812009] [<ffffffffa017d3a6>] ggtt_bind_vma+0x46/0x70 [i915]
[ 82.812045] [<ffffffffa017eb70>] i915_vma_bind+0x140/0x290 [i915]
[ 82.812081] [<ffffffffa01862b9>] i915_gem_object_do_pin+0x899/0xb00 [i915]
[ 82.812117] [<ffffffffa0186555>] i915_gem_object_pin+0x35/0x40 [i915]
[ 82.812154] [<ffffffffa019a23e>] intel_init_pipe_control+0xbe/0x210 [i915]
[ 82.812192] [<ffffffffa0197312>] intel_logical_rings_init+0xe2/0xde0 [i915]
[ 82.812232] [<ffffffffa0186fe3>] i915_gem_init+0xf3/0x130 [i915]
[ 82.812278] [<ffffffffa02097ed>] i915_driver_load+0xf2d/0x1770 [i915]
[ 82.812318] [<ffffffff81512474>] drm_dev_register+0xa4/0xb0
[ 82.812323] [<ffffffff8151467e>] drm_get_pci_dev+0xce/0x1e0
[ 82.812328] [<ffffffffa01472cf>] i915_pci_probe+0x2f/0x50 [i915]
[ 82.812360] [<ffffffff8143f907>] pci_device_probe+0x87/0xf0
[ 82.812366] [<ffffffff81535f89>] driver_probe_device+0x229/0x450
[ 82.812371] [<ffffffff81536233>] __driver_attach+0x83/0x90
[ 82.812375] [<ffffffff81533c61>] bus_for_each_dev+0x61/0xa0
[ 82.812380] [<ffffffff81535879>] driver_attach+0x19/0x20
[ 82.812384] [<ffffffff8153535f>] bus_add_driver+0x1ef/0x290
[ 82.812388] [<ffffffff81536e9b>] driver_register+0x5b/0xe0
[ 82.812393] [<ffffffff8143e83b>] __pci_register_driver+0x5b/0x60
[ 82.812398] [<ffffffff81514866>] drm_pci_init+0xd6/0x100
[ 82.812402] [<ffffffffa027c094>] 0xffffffffa027c094
[ 82.812406] [<ffffffff810003de>] do_one_initcall+0xae/0x1d0
[ 82.812412] [<ffffffff811595a0>] do_init_module+0x5b/0x1cb
[ 82.812417] [<ffffffff81106160>] load_module+0x1c20/0x2480
[ 82.812422] [<ffffffff81106bae>] SyS_finit_module+0x7e/0xa0
[ 82.812428] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73
[ 82.812433]
-> #0 (&dev->struct_mutex){+.+.+.}:
[ 82.812439] [<ffffffff810cbe59>] __lock_acquire+0x1fc9/0x20f0
[ 82.812443] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0
[ 82.812456] [<ffffffff8150d9e7>] drm_gem_mmap+0x1c7/0x270
[ 82.812460] [<ffffffff81196a14>] mmap_region+0x334/0x580
[ 82.812466] [<ffffffff81196fc4>] do_mmap+0x364/0x410
[ 82.812470] [<ffffffff8117b38d>] vm_mmap_pgoff+0x6d/0xa0
[ 82.812474] [<ffffffff811950f4>] SyS_mmap_pgoff+0x184/0x220
[ 82.812479] [<ffffffff8100a0fd>] SyS_mmap+0x1d/0x20
[ 82.812484] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73
[ 82.812489] other info that might help us debug this:
[ 82.812493] Chain exists of: &dev->struct_mutex --> s_active#6 --> &mm->mmap_sem
[ 82.812502] Possible unsafe locking scenario:
[ 82.812506] CPU0 CPU1 [ 82.812508] ---- ---- [ 82.812510] lock(&mm->mmap_sem); [ 82.812514] lock(s_active#6); [ 82.812519] lock(&mm->mmap_sem); [ 82.812522] lock(&dev->struct_mutex); [ 82.812526] *** DEADLOCK ***
[ 82.812531] 1 lock held by kms_setmode/5859:
[ 82.812533] #0: (&mm->mmap_sem){++++++}, at: [<ffffffff8117b364>] vm_mmap_pgoff+0x44/0xa0
[ 82.812541]
stack backtrace:
[ 82.812547] CPU: 0 PID: 5859 Comm: kms_setmode Not tainted 4.5.0-rc4-gfxbench+ #1
[ 82.812550] Hardware name: /NUC5CPYB, BIOS PYBSWCEL.86A.0040.2015.0814.1353 08/14/2015
[ 82.812553] 0000000000000000 ffff880079407bf0 ffffffff813f8505 ffffffff825fb270
[ 82.812560] ffffffff825c4190 ffff880079407c30 ffffffff810c84ac ffff880079407c90
[ 82.812566] ffff8800797ed328 ffff8800797ecb00 0000000000000001 ffff8800797ed350
[ 82.812573] Call Trace:
[ 82.812578] [<ffffffff813f8505>] dump_stack+0x67/0x92
[ 82.812582] [<ffffffff810c84ac>] print_circular_bug+0x1fc/0x310
[ 82.812586] [<ffffffff810cbe59>] __lock_acquire+0x1fc9/0x20f0
[ 82.812590] [<ffffffff810cc883>] lock_acquire+0xc3/0x1d0
[ 82.812594] [<ffffffff8150d9c1>] ? drm_gem_mmap+0x1a1/0x270
[ 82.812599] [<ffffffff8150d9e7>] drm_gem_mmap+0x1c7/0x270
[ 82.812603] [<ffffffff8150d9c1>] ? drm_gem_mmap+0x1a1/0x270
[ 82.812608] [<ffffffff81196a14>] mmap_region+0x334/0x580
[ 82.812612] [<ffffffff81196fc4>] do_mmap+0x364/0x410
[ 82.812616] [<ffffffff8117b38d>] vm_mmap_pgoff+0x6d/0xa0
[ 82.812629] [<ffffffff811950f4>] SyS_mmap_pgoff+0x184/0x220
[ 82.812633] [<ffffffff8100a0fd>] SyS_mmap+0x1d/0x20
[ 82.812637] [<ffffffff817bb81b>] entry_SYSCALL_64_fastpath+0x16/0x73Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 13 lines · On to, 2016-02-18 at 21:54 +0200, [email protected] wrote:
From: Ville Syrjälä <[email protected]>
PIPESTAT registers live in the display power well on VLV/CHV, so we shouldn't access them when things are powered down. Let's check whether the display interrupts are on or off before accessing the PIPESTAT registers.
Another option would be to read the PIPESTAT registers only when the IIR register indicates that there's a pending pipe event. But that would mean we might miss even more underrun reports than we do now, because the underrun status bit lives in PIPESTAT but doesn't actually generate an interrupt.
Quoted 4 lines
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93738
Cc Chris Wilson <[email protected]>Tested-by Chris Wilson <[email protected]>Signed-off-by Ville Syrjälä <[email protected]>
Btw, I think gen8_de_irq_handler would need to be fixed too for example by using display_irqs_enabled there as well.
Quoted 20 lines
---
drivers/gpu/drm/i915/i915_irq.c | 6 ++++++1 file changed, 6 insertions(+)drivers/gpu/drm/i915/i915_irq.c +0
-0@@ -1651,6 +1651,12 @@ static void valleyview_pipestat_irq_handler(struct drm_device *dev, u32 iir) int pipe;
spin_lock(&dev_priv->irq_lock);drivers/gpu/drm/i915/i915_irq.c +6
-0+ +if (!dev_priv->display_irqs_enabled) { +spin_unlock (&dev_priv->irq_lock); +return ; + } +
Quoted 3 lines
for_each_pipe(dev_priv, pipe){
i915_reg_treg;
u32 mask,iir_bit= 0;
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 19 lines · Imre Deak
Quoted 13 lines · On to, 2016-02-18 at 21:54 +0200, [email protected] wrote:
From: Ville Syrjälä <[email protected]>
PIPESTAT registers live in the display power well on VLV/CHV, so we shouldn't access them when things are powered down. Let's check whether the display interrupts are on or off before accessing the PIPESTAT registers.
Another option would be to read the PIPESTAT registers only when the IIR register indicates that there's a pending pipe event. But that would mean we might miss even more underrun reports than we do now, because the underrun status bit lives in PIPESTAT but doesn't actually generate an interrupt.
Quoted 4 lines
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93738
Cc Chris Wilson <[email protected]>Tested-by Chris Wilson <[email protected]>Signed-off-by Ville Syrjälä <[email protected]>
Quoted 4 lines
Reviewed-by Imre Deak <[email protected]>Btw, I think gen8_de_irq_handler would need to be fixed too for example by using display_irqs_enabled there as well.
I can take a look at that too. I also realized we'll need a synchronize_irq() in the vlv/chv power well code.
Quoted 24 lines
Quoted 24 lines
---
drivers/gpu/drm/i915/i915_irq.c | 6 ++++++1 file changed, 6 insertions(+)drivers/gpu/drm/i915/i915_irq.c +0
-0@@ -1651,6 +1651,12 @@ static void valleyview_pipestat_irq_handler(struct drm_device *dev, u32 iir) int pipe;
spin_lock(&dev_priv->irq_lock);drivers/gpu/drm/i915/i915_irq.c +6
-0+ +if (!dev_priv->display_irqs_enabled) { +spin_unlock (&dev_priv->irq_lock); +return ; + } +
for_each_pipe(dev_priv, pipe){
i915_reg_treg;
u32 mask,iir_bit= 0;
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Ville Syrjälä
AppliedQuoted 14 lines · Imre Deak
Quoted 13 lines · On to, 2016-02-18 at 21:54 +0200, [email protected] wrote:
From: Ville Syrjälä <[email protected]>
PIPESTAT registers live in the display power well on VLV/CHV, so we shouldn't access them when things are powered down. Let's check whether the display interrupts are on or off before accessing the PIPESTAT registers.
Another option would be to read the PIPESTAT registers only when the IIR register indicates that there's a pending pipe event. But that would mean we might miss even more underrun reports than we do now, because the underrun status bit lives in PIPESTAT but doesn't actually generate an interrupt.
Quoted 6 lines
Quoted 4 lines
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=93738
Cc Chris Wilson <[email protected]>Tested-by Chris Wilson <[email protected]>Signed-off-by Ville Syrjälä <[email protected]>Reviewed-by Imre Deak <[email protected]>
Pushed to dinq. Thanks for the review.
Quoted 27 lines
Btw, I think gen8_de_irq_handler would need to be fixed too for example by using display_irqs_enabled there as well.
Quoted 23 lines
---
drivers/gpu/drm/i915/i915_irq.c | 6 ++++++1 file changed, 6 insertions(+)drivers/gpu/drm/i915/i915_irq.c +0
-0@@ -1651,6 +1651,12 @@ static void valleyview_pipestat_irq_handler(struct drm_device *dev, u32 iir) int pipe;
spin_lock(&dev_priv->irq_lock);drivers/gpu/drm/i915/i915_irq.c +6
-0+ +if (!dev_priv->display_irqs_enabled) { +spin_unlock (&dev_priv->irq_lock); +return ; + } +
for_each_pipe(dev_priv, pipe){
i915_reg_treg;
u32 mask,iir_bit= 0;
Signature · 6 lines
Ville Syrjälä Intel OTC _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx