1. 19 6月, 2018 1 次提交
  2. 07 6月, 2018 1 次提交
  3. 11 5月, 2018 5 次提交
  4. 08 5月, 2018 2 次提交
  5. 03 5月, 2018 1 次提交
  6. 28 4月, 2018 3 次提交
  7. 19 4月, 2018 2 次提交
  8. 10 4月, 2018 1 次提交
  9. 09 4月, 2018 6 次提交
  10. 05 4月, 2018 1 次提交
    • C
      drm/i915: Only call finish_reset after a prepare_reset · 40da1d31
      Chris Wilson 提交于
      If we skip the intel_prepare_reset(), we should also skip the
      intel_display_reset(). If we we use a flag set by intel_prepare_reset()
      then we do not have to second guess based on external user controlled
      state whether or not the prepare was called before deciding to finish
      it after the reset. igt/gem_eio is one such example that may tweak
      i915.reset faster than the code is expecting, leading to
      
      [  190.233528] =====================================
      [  190.233534] WARNING: bad unlock balance detected!
      [  190.233540] 4.16.0-rc7-g335ef9849310-drmtip_10+ #1 Tainted: G     U
      [  190.233547] -------------------------------------
      [  190.233553] gem_eio/1348 is trying to release lock (crtc_ww_class_acquire) at:
      [  190.233569] [<ffffffff895c7810>] drm_modeset_acquire_fini+0x0/0x60
      [  190.233575] but there are no more locks to release!
      [  190.233580]
                     other info that might help us debug this:
      [  190.233588] 3 locks held by gem_eio/1348:
      [  190.233592]  #0:  (&f->f_pos_lock){+.+.}, at: [<00000000ab90c784>] __fdget_pos+0x3a/0x50
      [  190.233607]  #1:  (sb_writers#11){.+.+}, at: [<00000000e1529265>] vfs_write+0x188/0x1a0
      [  190.233622]  #2:  (&attr->mutex){+.+.}, at: [<0000000011f40afe>] simple_attr_write+0x36/0xd0
      [  190.233635]
                     stack backtrace:
      [  190.233644] CPU: 0 PID: 1348 Comm: gem_eio Tainted: G     U           4.16.0-rc7-g335ef9849310-drmtip_10+ #1
      [  190.233655] Hardware name: Dell Inc.                 OptiPlex GX280               /0G8310, BIOS A04 02/09/2005
      [  190.233664] Call Trace:
      [  190.233674]  dump_stack+0x67/0x95
      [  190.233682]  ? drm_modeset_backoff+0x1b0/0x1b0
      [  190.233690]  print_unlock_imbalance_bug+0xd2/0xe0
      [  190.233698]  ? drm_modeset_backoff+0x1b0/0x1b0
      [  190.233704]  lock_release+0x23e/0x300
      [  190.233712]  drm_modeset_acquire_fini+0x16/0x60
      [  190.233835]  intel_finish_reset+0x72/0x160 [i915]
      [  190.233894]  i915_reset_device+0x1e9/0x240 [i915]
      [  190.233953]  ? __intel_get_crtc_scanline+0x1c0/0x1c0 [i915]
      [  190.233962]  ? work_on_cpu_safe+0x50/0x50
      [  190.234020]  i915_handle_error+0x1f2/0x470 [i915]
      [  190.234031]  ? __might_fault+0x39/0x90
      [  190.234037]  ? __might_fault+0x39/0x90
      [  190.234099]  i915_wedged_set+0x7f/0xc0 [i915]
      [  190.234107]  simple_attr_write+0xb0/0xd0
      [  190.234117]  full_proxy_write+0x51/0x80
      [  190.234125]  __vfs_write+0x21/0x140
      [  190.234133]  ? rcu_read_lock_sched_held+0x6f/0x80
      [  190.234140]  ? rcu_sync_lockdep_assert+0x29/0x50
      [  190.234147]  ? __sb_start_write+0x152/0x1f0
      [  190.234152]  ? __sb_start_write+0x168/0x1f0
      [  190.234159]  vfs_write+0xbd/0x1a0
      [  190.234166]  SyS_write+0x40/0xa0
      [  190.234173]  ? do_syscall_64+0x19/0x1b0
      [  190.234180]  do_syscall_64+0x6b/0x1b0
      [  190.234188]  entry_SYSCALL_64_after_hwframe+0x42/0xb7
      [  190.234196] RIP: 0033:0x7f84c1b392b7
      [  190.234201] RSP: 002b:00007f84b6755b00 EFLAGS: 00000293 ORIG_RAX: 0000000000000001
      [  190.234211] RAX: ffffffffffffffda RBX: 0000000000000046 RCX: 00007f84c1b392b7
      [  190.234218] RDX: 0000000000000002 RSI: 000055ec20abc8d6 RDI: 0000000000000046
      [  190.234225] RBP: 000055ec20abc8d6 R08: 0000000000000000 R09: 0000000000000000
      [  190.234231] R10: 0000000000000000 R11: 0000000000000293 R12: 0000000000000002
      [  190.234238] R13: 0000000000000000 R14: 00007f84b0000b20 R15: 000055ec20ce4eb8
      
      Testcase: igt/gem_eio
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Reviewed-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180405123714.3638-1-chris@chris-wilson.co.uk
      40da1d31
  11. 30 3月, 2018 2 次提交
  12. 28 3月, 2018 3 次提交
  13. 24 3月, 2018 1 次提交
  14. 16 3月, 2018 2 次提交
  15. 14 3月, 2018 2 次提交
  16. 09 3月, 2018 1 次提交
    • M
      drm/i915: Handle pipe CRC around enabling/disabling pipe. · 033b7a23
      Maarten Lankhorst 提交于
      This will get rid of the following error:
      [   74.730271] WARNING: CPU: 4 PID: 0 at drivers/gpu/drm/drm_vblank.c:614 drm_calc_vbltimestamp_from_scanoutpos+0x13e/0x2f0
      [   74.730311] Modules linked in: vgem snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic i915 x86_pkg_temp_thermal intel_powerclamp coretemp snd_hda_intel crct10dif_pclmul snd_hda_codec crc32_pclmul snd_hwdep broadcom ghash_clmulni_intel snd_hda_core bcm_phy_lib snd_pcm tg3 lpc_ich mei_me mei prime_numbers
      [   74.730353] CPU: 4 PID: 0 Comm: swapper/4 Tainted: G     U           4.16.0-rc2-CI-CI_DRM_3822+ #1
      [   74.730355] Hardware name: Dell Inc. XPS 8300  /0Y2MRG, BIOS A06 10/17/2011
      [   74.730359] RIP: 0010:drm_calc_vbltimestamp_from_scanoutpos+0x13e/0x2f0
      [   74.730361] RSP: 0018:ffff88022fb03d10 EFLAGS: 00010086
      [   74.730365] RAX: ffffffffa0291d20 RBX: ffff88021a180000 RCX: 0000000000000001
      [   74.730367] RDX: ffffffff820e7db8 RSI: 0000000000000001 RDI: ffffffff82068cea
      [   74.730369] RBP: ffff88022fb03d70 R08: 0000000000000000 R09: ffffffff815d26d0
      [   74.730371] R10: 0000000000000000 R11: ffffffffa0161ca0 R12: 0000000000000001
      [   74.730373] R13: ffff880212448008 R14: ffff880212448330 R15: 0000000000000000
      [   74.730376] FS:  0000000000000000(0000) GS:ffff88022fb00000(0000) knlGS:0000000000000000
      [   74.730378] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [   74.730380] CR2: 000055edcbec9000 CR3: 0000000002210001 CR4: 00000000000606e0
      [   74.730382] Call Trace:
      [   74.730385]  <IRQ>
      [   74.730397]  drm_get_last_vbltimestamp+0x36/0x50
      [   74.730401]  drm_update_vblank_count+0x64/0x240
      [   74.730409]  drm_crtc_accurate_vblank_count+0x41/0x90
      [   74.730453]  display_pipe_crc_irq_handler+0x176/0x220 [i915]
      [   74.730497]  i9xx_pipe_crc_irq_handler+0xfe/0x150 [i915]
      [   74.730537]  ironlake_irq_handler+0x618/0xa30 [i915]
      [   74.730548]  __handle_irq_event_percpu+0x3c/0x340
      [   74.730556]  handle_irq_event_percpu+0x1b/0x50
      [   74.730561]  handle_irq_event+0x2f/0x50
      [   74.730566]  handle_edge_irq+0xe4/0x1b0
      [   74.730572]  handle_irq+0x11/0x20
      [   74.730576]  do_IRQ+0x5e/0x120
      [   74.730584]  common_interrupt+0x84/0x84
      [   74.730586]  </IRQ>
      [   74.730591] RIP: 0010:cpuidle_enter_state+0xaa/0x350
      [   74.730593] RSP: 0018:ffffc9000008beb8 EFLAGS: 00000212 ORIG_RAX: ffffffffffffffde
      [   74.730597] RAX: ffff880226b80040 RBX: 000000000031fc3e RCX: 0000000000000001
      [   74.730599] RDX: 0000000000000000 RSI: ffffffff8210fb59 RDI: ffffffff820c02e7
      [   74.730601] RBP: 0000000000000004 R08: 00000000000040af R09: 0000000000000018
      [   74.730603] R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000004
      [   74.730606] R13: ffffe8ffffd00430 R14: 0000001166120bf4 R15: ffffffff82294460
      [   74.730621]  ? cpuidle_enter_state+0xa6/0x350
      [   74.730629]  do_idle+0x188/0x1d0
      [   74.730636]  cpu_startup_entry+0x14/0x20
      [   74.730641]  start_secondary+0x129/0x160
      [   74.730646]  secondary_startup_64+0xa5/0xb0
      [   74.730660] Code: e1 48 c7 c2 b8 7d 0e 82 be 01 00 00 00 48 c7 c7 ea 8c 06 82 e8 64 ec ff ff 48 8b 83 c8 07 00 00 48 83 78 28 00 0f 84 e2 fe ff ff <0f> 0b 45 31 ed e9 db fe ff ff 41 b8 d3 4d 62 10 89 c8 6a 03 41
      [   74.730754] ---[ end trace 14b1345705b68565 ]---
      
      Changes since v1:
      - Don't try to apply CRC workaround when enabling pipe, it should already be enabled.
      Changes since v2:
      - Make crc functions for !DEBUGFS case inline.
      - Pass intel_crtc to crc functions.
      - Add comments to callsites.
      Changes since v3:
      - Cache selected source to pipe_crc->source.
      - Set pipe_crc->skipped to MIN_INT during disable to close a race condition.
      Changes since v4:
      - Handle fallout from setting pipe_crc->source in irq handler.
      
      Cc: Marta Löfstedt <marta.lofstedt@intel.com>
      Reported-by: NMarta Löfstedt <marta.lofstedt@intel.com>
      Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=105185Signed-off-by: NMaarten Lankhorst <maarten.lankhorst@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180308120202.52446-1-maarten.lankhorst@linux.intel.comReviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      033b7a23
  17. 06 3月, 2018 1 次提交
    • V
      drm: Don't pass clip to drm_atomic_helper_check_plane_state() · 81af63a4
      Ville Syrjälä 提交于
      Move the plane clip rectangle handling into
      drm_atomic_helper_check_plane_state(). Drivers no longer
      have to worry about such mundane details.
      
      v2: Convert armada, rcar, and sun4i as well
      v3: Resolve simple_kms_helper conflict
      
      Cc: Liviu Dudau <liviu.dudau@arm.com>
      Cc: Brian Starkey <brian.starkey@arm.com>
      Cc: Mali DP Maintainers <malidp@foss.arm.com>
      Cc: Daniel Vetter <daniel.vetter@intel.com>
      Cc: Gustavo Padovan <gustavo@padovan.org>
      Cc: Sean Paul <seanpaul@chromium.org>
      Cc: Philipp Zabel <p.zabel@pengutronix.de>
      Cc: CK Hu <ck.hu@mediatek.com>
      Cc: Neil Armstrong <narmstrong@baylibre.com>
      Cc: Rob Clark <robdclark@gmail.com>
      Cc: Ben Skeggs <bskeggs@redhat.com>
      Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
      Cc: Sandy Huang <hjc@rock-chips.com>
      Cc: "Heiko Stübner" <heiko@sntech.de>
      Cc: Maxime Ripard <maxime.ripard@free-electrons.com>
      Cc: Thierry Reding <thierry.reding@gmail.com>
      Cc: VMware Graphics <linux-graphics-maintainer@vmware.com>
      Cc: Sinclair Yeh <syeh@vmware.com>
      Cc: Thomas Hellstrom <thellstrom@vmware.com>
      Cc: Shawn Guo <shawnguo@kernel.org>
      Cc: Archit Taneja <architt@codeaurora.org>
      Cc: linux-amlogic@lists.infradead.org
      Cc: linux-arm-msm@vger.kernel.org
      Cc: freedreno@lists.freedesktop.org
      Cc: nouveau@lists.freedesktop.org
      Cc: linux-renesas-soc@vger.kernel.org
      Cc: linux-tegra@vger.kernel.org
      Cc: Russell King <rmk+kernel@armlinux.org.uk>
      Suggested-by: NDaniel Vetter <daniel@ffwll.ch>
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Reviewed-by: NThierry Reding <treding@nvidia.com>
      Reviewed-by: Archit Taneja <architt@codeaurora.org> #msm
      Link: https://patchwork.freedesktop.org/patch/msgid/20180123170857.13818-5-ville.syrjala@linux.intel.com
      Acked-by: Liviu Dudau <liviu.dudau@arm.com> #hdlcd,malidp
      Acked-by: Philipp Zabel <p.zabel@pengutronix.de> #imx,mtk
      Reviewed-by: NLaurent Pinchart <laurent.pinchart@ideasonboard.com>
      Reviewed-by: Sinclair Yeh <syeh@vmware.com> #vmwgfx
      Acked-by: Neil Armstrong <narmstrong@baylibre.com> #meson
      Acked-by: Shawn Guo <shawnguo@kernel.org> #zte
      81af63a4
  18. 05 3月, 2018 1 次提交
    • C
      drm/i915: Unwind vma pinning for intel_pin_and_fence_fb_obj error path · 7509702b
      Chris Wilson 提交于
      If we fail to acquire a fence when we must, we must unwind before
      reporting the error. Otherwise, we lose tracking of the vma pinning and
      eventually hit a bug like
      
      <3>[   46.163202] i915_vma_unpin:333 GEM_BUG_ON(!i915_vma_is_pinned(vma))
      <4>[   46.163424] ------------[ cut here ]------------
      <2>[   46.163429] kernel BUG at drivers/gpu/drm/i915/i915_vma.h:333!
      <4>[   46.163444] invalid opcode: 0000 [#1] PREEMPT SMP KASAN PTI
      <0>[   46.163451] Dumping ftrace buffer:
      <0>[   46.163457] ---------------------------------
      <0>[   46.163630]    <...>-84      1.... 46260767us : i915_gem_object_unpin_from_display_plane: i915_vma_unpin:333 GEM_BUG_ON(!i915_vma_is_pinned(vma))
      <0>[   46.163635] ---------------------------------
      <4>[   46.163638] Modules linked in: vgem i915 snd_hda_codec_analog snd_hda_codec_generic coretemp snd_hda_intel snd_hda_codec snd_hwdep snd_hda_core snd_pcm lpc_ich mei_me e1000e mei prime_numbers
      <4>[   46.163667] CPU: 1 PID: 84 Comm: kworker/u16:1 Tainted: G     U           4.16.0-rc3-gc07ef2c77d14-kasan_18+ #1
      <4>[   46.163671] Hardware name: Dell Inc. OptiPlex 755                 /0PU052, BIOS A08 02/19/2008
      <4>[   46.163743] Workqueue: events_unbound intel_atomic_commit_work [i915]
      <4>[   46.163809] RIP: 0010:i915_gem_object_unpin_from_display_plane+0x253/0x2f0 [i915]
      <4>[   46.163813] RSP: 0018:ffff8800624cfb48 EFLAGS: 00010286
      <4>[   46.163818] RAX: 000000000000000c RBX: ffff880064446c40 RCX: ffff8800653135b8
      <4>[   46.163822] RDX: dffffc0000000000 RSI: 0000000000000054 RDI: ffff8800651e30d0
      <4>[   46.163825] RBP: 00000000000003d0 R08: 0000000000000001 R09: ffff8800651e3158
      <4>[   46.163829] R10: 0000000000000000 R11: ffff8800651e30f0 R12: 0000000000000001
      <4>[   46.163832] R13: ffff880054c58620 R14: 0000000000000000 R15: dffffc0000000000
      <4>[   46.163836] FS:  0000000000000000(0000) GS:ffff880066040000(0000) knlGS:0000000000000000
      <4>[   46.163840] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      <4>[   46.163843] CR2: 00007f1fc6fb0000 CR3: 00000000526fe000 CR4: 00000000000006e0
      <4>[   46.163846] Call Trace:
      <4>[   46.163918]  intel_unpin_fb_vma+0xbd/0x300 [i915]
      <4>[   46.163990]  intel_cleanup_plane_fb+0x99/0xc0 [i915]
      <4>[   46.163998]  drm_atomic_helper_cleanup_planes+0x166/0x280
      <4>[   46.164071]  intel_atomic_commit_tail+0x1594/0x33a0 [i915]
      <4>[   46.164081]  ? process_one_work+0x66e/0x1460
      <4>[   46.164151]  ? skl_update_crtcs+0x9c0/0x9c0 [i915]
      <4>[   46.164157]  ? lock_acquire+0x13d/0x390
      <4>[   46.164161]  ? lock_acquire+0x13d/0x390
      <4>[   46.164169]  process_one_work+0x71a/0x1460
      <4>[   46.164175]  ? __schedule+0x838/0x1e50
      <4>[   46.164182]  ? pwq_dec_nr_in_flight+0x2b0/0x2b0
      <4>[   46.164188]  ? _raw_spin_lock_irq+0xa/0x40
      <4>[   46.164194]  worker_thread+0xdf/0xf60
      <4>[   46.164204]  ? process_one_work+0x1460/0x1460
      <4>[   46.164209]  kthread+0x2cf/0x3c0
      <4>[   46.164213]  ? _kthread_create_on_node+0xa0/0xa0
      <4>[   46.164218]  ret_from_fork+0x3a/0x50
      <4>[   46.164227] Code: e8 78 d9 cd e8 48 8b 35 cc 9e 47 00 49 c7 c0 c0 31 84 c0 b9 4d 01 00 00 48 c7 c2 e0 80 84 c0 48 c7 c7 0e bb 57 c0 e8 5d 4b df e8 <0f> 0b 48 c7 c1 c0 30 84 c0 ba 4e 01 00 00 48 c7 c6 e0 80 84 c0
      <1>[   46.164368] RIP: i915_gem_object_unpin_from_display_plane+0x253/0x2f0 [i915] RSP: ffff8800624cfb48
      
      Fixes: 85798ac9 ("drm/i915: Fail if we can't get a fence for gen2/3 tiled scanout")
      Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20180305103312.29492-1-chris@chris-wilson.co.uk
      7509702b
  19. 02 3月, 2018 4 次提交