1. 31 8月, 2022 1 次提交
  2. 29 8月, 2022 2 次提交
  3. 15 8月, 2022 1 次提交
  4. 18 7月, 2022 1 次提交
  5. 07 7月, 2022 1 次提交
  6. 14 6月, 2022 1 次提交
  7. 03 6月, 2022 1 次提交
  8. 01 6月, 2022 1 次提交
  9. 28 5月, 2022 1 次提交
  10. 25 4月, 2022 1 次提交
  11. 21 4月, 2022 2 次提交
  12. 12 4月, 2022 1 次提交
    • L
      drm/i915/dg2: Do not explode on phy calibration error · 82c362f2
      Lucas De Marchi 提交于
      When the PHY fails on calibration we were previously skipping the ddi
      initialization. However the driver is not really prepared for that,
      ultimately leading to a NULL pointer dereference:
      
      [   75.748348] i915 0000:03:00.0: [drm:intel_modeset_init_nogem [i915]] SNPS PHY A failed to calibrate; output will not be used.
      ...
      [   75.750336] i915 0000:03:00.0: [drm:intel_modeset_setup_hw_state [i915]] [CRTC:80:pipe A] hw state readout: enabled
      ...
      
      ( no DDI A/PHY A )
      [   75.753080] i915 0000:03:00.0: [drm:intel_modeset_setup_hw_state [i915]] [ENCODER:235:DDI B/PHY B] hw state readout: disabled, pipe A
      [   75.753164] i915 0000:03:00.0: [drm:intel_modeset_setup_hw_state [i915]] [ENCODER:245:DDI C/PHY C] hw state readout: disabled, pipe A
      ...
      [   75.754425] i915 0000:03:00.0: [drm] *ERROR* crtc 80: Can't calculate constants, dotclock = 0!
      [   75.765558] i915 0000:03:00.0: drm_WARN_ON_ONCE(drm_drv_uses_atomic_modeset(dev))
      [   75.765569] WARNING: CPU: 5 PID: 1759 at drivers/gpu/drm/drm_vblank.c:728 drm_crtc_vblank_helper_get_vblank_timestamp_internal+0x347/0x360
      ...
      [   75.781230] BUG: kernel NULL pointer dereference, address: 000000000000007c
      [   75.788198] #PF: supervisor read access in kernel mode
      [   75.793347] #PF: error_code(0x0000) - not-present page
      [   75.798480] PGD 0 P4D 0
      [   75.801019] Oops: 0000 [#1] PREEMPT SMP NOPTI
      [   75.805377] CPU: 5 PID: 1759 Comm: modprobe Tainted: G        W         5.18.0-rc1-demarchi+ #199
      [   75.827613] RIP: 0010:icl_aux_power_well_disable+0x3b/0x200 [i915]
      [   75.833890] Code: 83 ec 30 65 48 8b 04 25 28 00 00 00 48 89 44 24 28 48 8b 06 0f b6 70 1c f6 40 20 04 8d 56 fa 0f 45 f2 e8 88 bd ff ff 48 89 ef <8b> 70 7c e8 ed 67 ff ff 48 89 ef 89 c6 e8 73 67 ff ff 84 c0 75 0a
      [   75.852629] RSP: 0018:ffffc90003a7fb30 EFLAGS: 00010246
      [   75.857852] RAX: 0000000000000000 RBX: ffff8881145e8f10 RCX: 0000000000000000
      [   75.864978] RDX: ffff888115220840 RSI: 0000000000000000 RDI: ffff888115220000
      [   75.872106] RBP: ffff888115220000 R08: ffff88888effffe8 R09: 00000000fffdffff
      [   75.879234] R10: ffff88888e200000 R11: ffff88888ed00000 R12: ffff8881145e8f10
      [   75.886363] R13: 0000000000000001 R14: ffff888115223240 R15: 0000000000000000
      [   75.893490] FS:  00007ff6e753a740(0000) GS:ffff88888f680000(0000) knlGS:0000000000000000
      [   75.901573] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [   75.907313] CR2: 000000000000007c CR3: 00000001216a6001 CR4: 0000000000770ee0
      [   75.914446] PKRU: 55555554
      [   75.917153] Call Trace:
      [   75.919603]  <TASK>
      [   75.921709]  intel_power_domains_sanitize_state+0x88/0xb0 [i915]
      [   75.927814]  intel_modeset_init_nogem+0x317/0xef0 [i915]
      [   75.933205]  i915_driver_probe+0x5f6/0xdf0 [i915]
      [   75.937976]  i915_pci_probe+0x51/0x1d0 [i915]
      
      We skip the initialization of PHY A, but later we try to find out what
      is the phy for that power well and dereference dig_port, which is NULL.
      
      Failing the PHY calibration could be left as a warning or error, like it
      was before commit b4eb76d8 ("drm/i915/dg2: Skip output init on PHY
      calibration failure"). However that often fails for outputs not being
      used, which would make the warning/error appear on systems that have no
      visible issues. Anyway, there is still a need to fix those failures,
      but that is left for later.
      Signed-off-by: NLucas De Marchi <lucas.demarchi@intel.com>
      Reviewed-by: NMatt Roper <matthew.d.roper@intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20220410061537.4187383-1-lucas.demarchi@intel.com
      82c362f2
  13. 30 3月, 2022 1 次提交
  14. 16 3月, 2022 1 次提交
  15. 15 3月, 2022 3 次提交
  16. 03 3月, 2022 1 次提交
  17. 25 2月, 2022 1 次提交
  18. 22 2月, 2022 1 次提交
  19. 15 2月, 2022 2 次提交
    • V
      drm/i915: Change bigjoiner state tracking to use the pipe bitmask · a6e7a006
      Ville Syrjälä 提交于
      Get rid of the inflexible bigjoiner_linked_crtc pointer thing
      and just track things as a bitmask of pipes instead. We can
      also nuke the bigjoiner_slave boolean as the role of the pipe
      can be determined from its position in the bitmask.
      
      It might be possible to nuke the bigjoiner boolean as well
      if we make encoder.compute_config() do the bitmask assignment
      directly for the master pipe. But for now I left that alone so
      that encoer.compute_config() will just flag the state as needing
      bigjoiner, and the intel_atomic_check_bigjoiner() is still
      responsible for determining the bitmask. But that may have to change
      as the encoder may be in the best position to determine how
      exactly we should populate the bitmask.
      
      Most places that just looked at the single bigjoiner_linked_crtc
      now iterate over the whole bitmask, eliminating the singular
      slave pipe assumption.
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20220203183823.22890-11-ville.syrjala@linux.intel.comReviewed-by: NManasi Navare <manasi.d.navare@intel.com>
      a6e7a006
    • V
      drm/i915: Introduce intel_crtc_is_bigjoiner_{slave,master}() · df529053
      Ville Syrjälä 提交于
      Introduce helpers to query whether the crtc is the slave/master
      for bigjoiner. This decouples most places from the exact
      state layout we use to track this relationship, allowing us
      to change and extend it more easily.
      
      Performed with cocci:
      @@
      expression S, E;
      @@
      (
        S->bigjoiner_slave = E;
      |
      - S->bigjoiner_slave
      + intel_crtc_is_bigjoiner_slave(S)
      )
      
      @@
      expression S, E;
      @@
      (
      - E && S->bigjoiner && !intel_crtc_is_bigjoiner_slave(S)
      + E && intel_crtc_is_bigjoiner_master(S)
      |
      - S->bigjoiner && !intel_crtc_is_bigjoiner_slave(S)
      + intel_crtc_is_bigjoiner_master(S)
      )
      
      @@
      expression S;
      @@
      - (intel_crtc_is_bigjoiner_master(S))
      + intel_crtc_is_bigjoiner_master(S)
      
      @@
      expression S, E1, E2, E3;
      @@
      - intel_crtc_is_bigjoiner_slave(S) ? E1 : S->bigjoiner ? E2 : E3
      + intel_crtc_is_bigjoiner_slave(S) ? E1 : intel_crtc_is_bigjoiner_master(S) ? E2 : E3
      
      @@
      typedef bool;
      @@
      + bool intel_crtc_is_bigjoiner_slave(const struct intel_crtc_state *crtc_state)
      + {
      + 	return crtc_state->bigjoiner_slave;
      + }
      +
        intel_master_crtc(...) {...}
      
      @@
      typedef bool;
      @@
      + bool intel_crtc_is_bigjoiner_master(const struct intel_crtc_state *crtc_state)
      + {
      + 	return crtc_state->bigjoiner && !crtc_state->bigjoiner_slave;
      + }
      +
        intel_master_crtc(...) {...}
      
      @@
      typedef bool;
      identifier S;
      @@
      - bool is_trans_port_sync_mode(const struct intel_crtc_state *S);
      + bool is_trans_port_sync_mode(const struct intel_crtc_state *state);
      + bool intel_crtc_is_bigjoiner_slave(const struct intel_crtc_state *crtc_state);
      + bool intel_crtc_is_bigjoiner_master(const struct intel_crtc_state *crtc_state);
      Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20220203183823.22890-7-ville.syrjala@linux.intel.comReviewed-by: NAnkit Nautiyal <ankit.k.nautiyal@intel.com>
      df529053
  20. 01 2月, 2022 6 次提交
  21. 28 1月, 2022 1 次提交
  22. 26 1月, 2022 1 次提交
  23. 24 1月, 2022 1 次提交
  24. 17 1月, 2022 1 次提交
  25. 14 1月, 2022 1 次提交
  26. 12 1月, 2022 2 次提交
  27. 09 12月, 2021 1 次提交
  28. 10 11月, 2021 1 次提交
  29. 09 11月, 2021 1 次提交
    • V
      drm/i915/hdmi: Turn DP++ TMDS output buffers back on in encoder->shutdown() · cecbc0c7
      Ville Syrjälä 提交于
      Looks like our VBIOS/GOP generally fail to turn the DP dual mode adater
      TMDS output buffers back on after a reboot. This leads to a black screen
      after reboot if we turned the TMDS output buffers off prior to reboot.
      And if i915 decides to do a fastboot the black screen will persist even
      after i915 takes over.
      
      Apparently this has been a problem ever since commit b2ccb822 ("drm/i915:
      Enable/disable TMDS output buffers in DP++ adaptor as needed") if one
      rebooted while the display was turned off. And things became worse with
      commit fe0f1e3b ("drm/i915: Shut down displays gracefully on reboot")
      since now we always turn the display off before a reboot.
      
      This was reported on a RKL, but I confirmed the same behaviour on my
      SNB as well. So looks pretty universal.
      
      Let's fix this by explicitly turning the TMDS output buffers back on
      in the encoder->shutdown() hook. Note that this gets called after irqs
      have been disabled, so the i2c communication with the DP dual mode
      adapter has to be performed via polling (which the gmbus code is
      perfectly happy to do for us).
      
      We also need a bit of care in handling DDI encoders which may or may
      not be set up for HDMI output. Specifically ddc_pin will not be
      populated for a DP only DDI encoder, in which case we don't want to
      call intel_gmbus_get_adapter(). We can handle that by simply doing
      the dual mode adapter type check before calling
      intel_gmbus_get_adapter().
      
      Cc: <stable@vger.kernel.org> # v5.11+
      Fixes: fe0f1e3b ("drm/i915: Shut down displays gracefully on reboot")
      Closes: https://gitlab.freedesktop.org/drm/intel/-/issues/4371Signed-off-by: NVille Syrjälä <ville.syrjala@linux.intel.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20211029191802.18448-2-ville.syrjala@linux.intel.comReviewed-by: NStanislav Lisovskiy <stanislav.lisovskiy@intel.com>
      (cherry picked from commit 49c55f7b)
      Signed-off-by: NRodrigo Vivi <rodrigo.vivi@intel.com>
      cecbc0c7