1. 04 4月, 2020 4 次提交
  2. 01 4月, 2020 4 次提交
  3. 28 3月, 2020 3 次提交
  4. 26 3月, 2020 1 次提交
    • J
      drm/i915/ddi: use struct drm_device based logging · 47bdb1ca
      Jani Nikula 提交于
      Convert all the DRM_* logging macros to the struct drm_device based
      macros to provide device specific logging.
      
      No functional changes.
      
      Generated using the following semantic patch, originally written by
      Wambui Karuga <wambui.karugax@gmail.com>, with manual fixups on top:
      
      @@
      identifier fn, T;
      @@
      
      fn(...,struct drm_i915_private *T,...) {
      <+...
      (
      -DRM_INFO(
      +drm_info(&T->drm,
      ...)
      |
      -DRM_NOTE(
      +drm_notice(&T->drm,
      ...)
      |
      -DRM_ERROR(
      +drm_err(&T->drm,
      ...)
      |
      -DRM_WARN(
      +drm_warn(&T->drm,
      ...)
      |
      -DRM_DEBUG_DRIVER(
      +drm_dbg(&T->drm,
      ...)
      |
      -DRM_DEBUG_KMS(
      +drm_dbg_kms(&T->drm,
      ...)
      |
      -DRM_DEBUG_ATOMIC(
      +drm_dbg_atomic(&T->drm,
      ...)
      )
      ...+>
      }
      
      @@
      identifier fn, T;
      @@
      
      fn(...) {
      ...
      struct drm_i915_private *T = ...;
      <+...
      (
      -DRM_INFO(
      +drm_info(&T->drm,
      ...)
      |
      -DRM_NOTE(
      +drm_notice(&T->drm,
      ...)
      |
      -DRM_ERROR(
      +drm_err(&T->drm,
      ...)
      |
      -DRM_WARN(
      +drm_warn(&T->drm,
      ...)
      |
      -DRM_DEBUG_DRIVER(
      +drm_dbg(&T->drm,
      ...)
      |
      -DRM_DEBUG_KMS(
      +drm_dbg_kms(&T->drm,
      ...)
      |
      -DRM_DEBUG_ATOMIC(
      +drm_dbg_atomic(&T->drm,
      ...)
      )
      ...+>
      }
      
      Cc: Wambui Karuga <wambui.karugax@gmail.com>
      Reviewed-by: NDaniel Vetter <daniel.vetter@ffwll.ch>
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/e09bb6e97b2fbc44303acce0523dc35e3e74a456.1584714939.git.jani.nikula@intel.com
      47bdb1ca
  5. 05 3月, 2020 1 次提交
  6. 04 3月, 2020 1 次提交
  7. 03 3月, 2020 4 次提交
  8. 23 2月, 2020 1 次提交
    • P
      drm/i915/display/ddi: Make WARN* drm specific where drm_device ptr is available · 1de143cc
      Pankaj Bharadiya 提交于
      drm specific WARN* calls include device information in the
      backtrace, so we know what device the warnings originate from.
      
      Covert all the calls of WARN* with device specific drm_WARN*
      variants in functions where drm_device or drm_i915_private struct
      pointer is readily available.
      
      The conversion was done automatically with below coccinelle semantic
      patch. checkpatch errors/warnings are fixed manually.
      
      @rule1@
      identifier func, T;
      @@
      func(...) {
      ...
      struct drm_device *T = ...;
      <...
      (
      -WARN(
      +drm_WARN(T,
      ...)
      |
      -WARN_ON(
      +drm_WARN_ON(T,
      ...)
      |
      -WARN_ONCE(
      +drm_WARN_ONCE(T,
      ...)
      |
      -WARN_ON_ONCE(
      +drm_WARN_ON_ONCE(T,
      ...)
      )
      ...>
      }
      
      @rule2@
      identifier func, T;
      @@
      func(struct drm_device *T,...) {
      <...
      (
      -WARN(
      +drm_WARN(T,
      ...)
      |
      -WARN_ON(
      +drm_WARN_ON(T,
      ...)
      |
      -WARN_ONCE(
      +drm_WARN_ONCE(T,
      ...)
      |
      -WARN_ON_ONCE(
      +drm_WARN_ON_ONCE(T,
      ...)
      )
      ...>
      }
      
      @rule3@
      identifier func, T;
      @@
      func(...) {
      ...
      struct drm_i915_private *T = ...;
      <+...
      (
      -WARN(
      +drm_WARN(&T->drm,
      ...)
      |
      -WARN_ON(
      +drm_WARN_ON(&T->drm,
      ...)
      |
      -WARN_ONCE(
      +drm_WARN_ONCE(&T->drm,
      ...)
      |
      -WARN_ON_ONCE(
      +drm_WARN_ON_ONCE(&T->drm,
      ...)
      )
      ...+>
      }
      
      @rule4@
      identifier func, T;
      @@
      func(struct drm_i915_private *T,...) {
      <+...
      (
      -WARN(
      +drm_WARN(&T->drm,
      ...)
      |
      -WARN_ON(
      +drm_WARN_ON(&T->drm,
      ...)
      |
      -WARN_ONCE(
      +drm_WARN_ONCE(&T->drm,
      ...)
      |
      -WARN_ON_ONCE(
      +drm_WARN_ON_ONCE(&T->drm,
      ...)
      )
      ...+>
      }
      Signed-off-by: NPankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
      Signed-off-by: NJani Nikula <jani.nikula@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20200220165507.16823-3-pankaj.laxminarayan.bharadiya@intel.com
      1de143cc
  9. 20 2月, 2020 1 次提交
  10. 15 2月, 2020 1 次提交
  11. 11 2月, 2020 3 次提交
  12. 07 2月, 2020 1 次提交
    • J
      drm/i915/display: Set TRANS_DDI_MODE_SELECT to default value when clearing DDI select · 919e4f07
      José Roberto de Souza 提交于
      TGL is suffering of timeouts and fifo underruns when disabling
      transcoder in MST mode, this is fixed by set TRANS_DDI_MODE_SELECT to
      0(HDMI mode) when clearing DDI select.
      
      Although BSpec disable sequence don't require this step, it is a
      harmless change and it is also done by Windows driver.
      Anyhow HW team was notified about that but it can take some time to
      documentation to be updated.
      
      A case that always lead to those issues is:
      - do a modeset enabling pipe A and pipe B in the same MST stream
      leaving A as master
      - disable pipe A, promote B as master doing a full modeset in A
      - enable pipe A, changing the master transcoder back to A(doing a
      full modeset in B)
      - Pow: underruns and timeouts
      
      The transcoders involved will only work again when complete disabled
      and their power wells turned off causing a reset in their registers.
      
      v2: Setting TRANS_DDI_MODE_SELECT to default when clearing DDI select
      not anymore when disabling TRANS_DDI, both work but this one looks
      more safe. (Ville comment)
      
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Signed-off-by: NJosé Roberto de Souza <jose.souza@intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20200203225549.152301-1-jose.souza@intel.com
      919e4f07
  13. 05 2月, 2020 1 次提交
  14. 31 1月, 2020 2 次提交
  15. 29 1月, 2020 1 次提交
  16. 25 1月, 2020 1 次提交
  17. 22 1月, 2020 2 次提交
  18. 21 1月, 2020 4 次提交
  19. 15 1月, 2020 1 次提交
  20. 14 1月, 2020 1 次提交
  21. 10 1月, 2020 1 次提交
    • V
      drm/i915: Fix MST disable sequence · 7829c92b
      Ville Syrjälä 提交于
      When moving the pipe disable & co. function calls from
      haswell_crtc_disable() into the encoder .post_disable() hooks I
      neglected to account for the MST vs. DDI interactions properly.
      This now leads us to call these functions two times for the last
      MST stream (once from the MST code and a second time from the DDI
      code). The calls from the DDI code should only be done for SST
      and not MST. Add the proper check for that.
      
      This results in an MCE on ICL. My vague theory is that we turn off
      the transcoder clock from the MST code and then we proceed to touch
      something in the DDI code which still depends on that clock causing
      the hardware to become upset. Though I can't really explain why
      Stan's hack of omitting the pipe disable in the MST code would avoid
      the MCE since we should still be turning off the transcoder clock.
      But maybe there's something magic in the hw that keeps the clock on
      as long as the pipe is on. Or maybe the clock isn't the problem and
      we now touch something in the DDI disable code that really does need
      the pipe to be still enabled.
      
      v2: Rebase to latest drm-tip
      
      Cc: José Roberto de Souza <jose.souza@intel.com>
      Cc: Manasi Navare <manasi.d.navare@intel.com>
      Reported-by: NStanislav Lisovskiy <stanislav.lisovskiy@intel.com>
      Closes: https://gitlab.freedesktop.org/drm/intel/issues/901
      Fixes: 773b4b54 ("drm/i915: Move stuff from haswell_crtc_disable() into encoder .post_disable()")
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20200108144550.29280-1-ville.syrjala@linux.intel.comReviewed-by: NJosé Roberto de Souza <jose.souza@intel.com>
      7829c92b
  22. 09 1月, 2020 1 次提交
    • J
      drm/i915/display: Fix warning about MST and DDI restrictions · 542dfab5
      José Roberto de Souza 提交于
      Capturing the restrictions of the BSpec pages bellow:
      
      SKL and CNL do not support MST in DDI E, DDI E only support 2 lanes
      and it is mostly used to support a 4 lanes eDP panel together with
      DDI A.
      ICL's DDI E support MST just like other ports but DDI A is still eDP
      and MIPI only.
      TGL supports MST in any DDI, including DDI A but TGL has it's own
      ddi_pre_enable_dp function already without any warning.
      
      [  215.579791] ------------[ cut here ]------------
      [  215.579794] WARN_ON(is_mst && (port == PORT_A || port == PORT_E))
      [  215.579875] WARNING: CPU: 0 PID: 268 at drivers/gpu/drm/i915/display/intel_ddi.c:3576 intel_ddi_pre_enable+0x124/0xea0 [i915]
      [  215.579878] Modules linked in: snd_hda_codec_hdmi snd_hda_codec_realtek snd_hda_codec_generic i915 btusb btrtl btbcm btintel bluetooth prime_numbers snd_hda_intel snd_intel_dspcfg snd_hda_codec e1000e snd_hwdep snd_hda_core asix mei_hdcp cdc_ether x86_pkg_temp_thermal mei_me snd_pcm r8152 coretemp usbnet mei crct10dif_pclmul mii ptp ecdh_generic crc32_pclmul i2c_i801 ecc pps_core ghash_clmulni_intel thunderbolt
      [  215.579905] CPU: 0 PID: 268 Comm: kworker/0:2 Tainted: G        W         5.4.0-rc8-zeh+ #1307
      [  215.579907] Hardware name: Intel Corporation Ice Lake Client Platform/IceLake U DDR4 SODIMM PD RVP TLC, BIOS ICLSFWR1.R00.3201.A00.1905140358 05/14/2019
      [  215.579912] Workqueue: events_long drm_dp_mst_link_probe_work
      [  215.579975] RIP: 0010:intel_ddi_pre_enable+0x124/0xea0 [i915]
      [  215.579978] Code: ff 8b 7c 24 10 89 44 24 30 85 ff 74 1f f7 44 24 18 fb ff ff ff 75 15 48 c7 c6 98 fa 48 a0 48 c7 c7 d3 df 4a a0 e8 cf d5 d0 e0 <0f> 0b 0f b6 4c 24 2c 41 8b b5 04 06 00 00 4c 89 e7 41 0f b6 95 0c
      [  215.579980] RSP: 0018:ffffc90001a5f990 EFLAGS: 00010286
      [  215.579984] RAX: 0000000000000000 RBX: ffff88848356a000 RCX: 0000000000000000
      [  215.579986] RDX: 0000000000001df1 RSI: ffff88849340c998 RDI: ffffffff821489c5
      [  215.579989] RBP: ffff88848356a000 R08: 00000000c021a419 R09: 0000000000000000
      [  215.579991] R10: 0000000000000000 R11: 0000000000000000 R12: ffff88848356a118
      [  215.579994] R13: ffff88847f39c000 R14: ffff88847fe70000 R15: ffff88848356a000
      [  215.579996] FS:  0000000000000000(0000) GS:ffff88849f800000(0000) knlGS:0000000000000000
      [  215.579999] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [  215.580001] CR2: 000055d3d5a26bc0 CR3: 0000000480ba6005 CR4: 0000000000760ef0
      [  215.580004] PKRU: 55555554
      [  215.580006] Call Trace:
      [  215.580014]  ? drm_dp_mst_topology_put_port+0x6f/0x130
      [  215.580072]  intel_mst_pre_enable_dp+0x14b/0x170 [i915]
      [  215.580129]  intel_encoders_pre_enable+0x76/0x90 [i915]
      [  215.580191]  haswell_crtc_enable+0x84/0x880 [i915]
      [  215.580266]  intel_update_crtc+0x1e4/0x200 [i915]
      [  215.580333]  skl_commit_modeset_enables+0x287/0x420 [i915]
      [  215.580405]  intel_atomic_commit_tail+0x332/0x14e0 [i915]
      [  215.580410]  ? queue_work_on+0x41/0x70
      [  215.580489]  intel_atomic_commit+0x31e/0x350 [i915]
      [  215.580500]  drm_client_modeset_commit_atomic+0x18b/0x220
      [  215.580523]  drm_client_modeset_commit_force+0x4d/0x180
      [  215.580531]  drm_fb_helper_restore_fbdev_mode_unlocked+0x46/0xa0
      [  215.580538]  drm_fb_helper_set_par+0x27/0x50
      [  215.580543]  drm_fb_helper_hotplug_event.part.0+0xa7/0xc0
      [  215.580549]  drm_kms_helper_hotplug_event+0x21/0x30
      [  215.580553]  process_one_work+0x25b/0x5b0
      [  215.580566]  worker_thread+0x4b/0x3b0
      [  215.580578]  kthread+0x100/0x140
      [  215.580581]  ? process_one_work+0x5b0/0x5b0
      [  215.580585]  ? kthread_park+0x80/0x80
      [  215.580591]  ret_from_fork+0x24/0x50
      [  215.580603] irq event stamp: 1393930
      [  215.580606] hardirqs last  enabled at (1393929): [<ffffffff8112a013>] vprintk_emit+0x143/0x330
      [  215.580609] hardirqs last disabled at (1393930): [<ffffffff81001cfa>] trace_hardirqs_off_thunk+0x1a/0x20
      [  215.580613] softirqs last  enabled at (1393434): [<ffffffff81c00389>] __do_softirq+0x389/0x47f
      [  215.580618] softirqs last disabled at (1393423): [<ffffffff810b7199>] irq_exit+0xa9/0xc0
      [  215.580621] ---[ end trace afd44ea9caa6373e ]---
      
      BSpec: 4217
      BSpec: 14004
      BSpec: 20584
      BSpec: 50583
      Cc: Matt Roper <matthew.d.roper@intel.com>
      Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
      Cc: Lucas De Marchi <lucas.demarchi@intel.com>
      Signed-off-by: NJosé Roberto de Souza <jose.souza@intel.com>
      Reviewed-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20200107170922.153612-2-jose.souza@intel.com
      542dfab5