1. 04 Jun, 2019 1 commit
    • Noralf Trønnes's avatar
      drm/fb-helper: Remove drm_fb_helper_crtc · d81294af
      Noralf Trønnes authored
      struct drm_fb_helper_crtc is now just a wrapper around drm_mode_set so
      use that directly instead and attach it as a modeset array onto
      drm_client_dev. drm_fb_helper will use this array to store its modesets
      which means it will always initialize a drm_client, but it will not
      register the client (callbacks) unless it's the generic fbdev emulation.
      
      Code will later be moved to drm_client, so add code there in a new file
      drm_client_modeset.c with MIT license to match drm_fb_helper.c.
      
      The modeset connector array size is hardcoded for the cloned case to avoid
      having to pass in a value from the driver. A value of 8 is chosen to err
      on the safe side. This means that the max connector argument for
      drm_fb_helper_init() and drm_fb_helper_fbdev_setup() isn't used anymore,
      a todo entry for this is added.
      
      In pan_display_atomic() restore_fbdev_mode_force() is used instead of
      restore_fbdev_mode_atomic() because that one will later become internal
      to drm_client_modeset.
      
      Locking order:
      1. drm_fb_helper->lock
      2. drm_master_internal_acquire
      3. drm_client_dev->modeset_mutex
      
      v6: Improve commit message (Sam Ravnborg)
      
      v3:
      - Use full drm_client_init/release for the modesets (Daniel Vetter)
      - drm_client_for_each_modeset: use lockdep_assert_held (Daniel Vetter)
      - Hook up to Documentation/gpu/drm-client.rst (Daniel Vetter)
      
      v2:
      - Add modesets array to drm_client (Daniel Vetter)
      - Use a new file for the modeset code (Daniel Vetter)
      - File has to be MIT licensed (Emmanuel Vadot)
      - Add copyrights from drm_fb_helper.c
      Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
      Reviewed-by: default avatarSam Ravnborg <sam@ravnborg.org>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190531140117.37751-3-noralf@tronnes.org
      d81294af
  2. 03 Jun, 2019 6 commits
  3. 31 May, 2019 30 commits
  4. 30 May, 2019 1 commit
  5. 29 May, 2019 2 commits
    • Imre Deak's avatar
      drm/mst: Fix MST sideband up-reply failure handling · d8fd3722
      Imre Deak authored
      Fix the breakage resulting in the stacktrace below, due to tx queue
      being full when trying to send an up-reply. txmsg->seqno is -1 in this
      case leading to a corruption of the mstb object by
      
      	txmsg->dst->tx_slots[txmsg->seqno] = NULL;
      
      in process_single_up_tx_qlock().
      
      [  +0,005162] [drm:process_single_tx_qlock [drm_kms_helper]] set_hdr_from_dst_qlock: failed to find slot
      [  +0,000015] [drm:drm_dp_send_up_ack_reply.constprop.19 [drm_kms_helper]] failed to send msg in q -11
      [  +0,000939] BUG: kernel NULL pointer dereference, address: 00000000000005a0
      [  +0,006982] #PF: supervisor write access in kernel mode
      [  +0,005223] #PF: error_code(0x0002) - not-present page
      [  +0,005135] PGD 0 P4D 0
      [  +0,002581] Oops: 0002 [#1] PREEMPT SMP NOPTI
      [  +0,004359] CPU: 1 PID: 1200 Comm: kworker/u16:3 Tainted: G     U            5.2.0-rc1+ #410
      [  +0,008433] Hardware name: Intel Corporation Ice Lake Client Platform/IceLake U DDR4 SODIMM PD RVP, BIOS ICLSFWR1.R00.3175.A00.1904261428 04/26/2019
      [  +0,013323] Workqueue: i915-dp i915_digport_work_func [i915]
      [  +0,005676] RIP: 0010:queue_work_on+0x19/0x70
      [  +0,004372] Code: ff ff ff 0f 1f 40 00 66 2e 0f 1f 84 00 00 00 00 00 41 56 49 89 f6 41 55 41 89 fd 41 54 55 53 48 89 d3 9c 5d fa e8 e7 81 0c 00 <f0> 48 0f ba 2b 00 73 31 45 31 e4 f7 c5 00 02 00 00 74 13 e8 cf 7f
      [  +0,018750] RSP: 0018:ffffc900007dfc50 EFLAGS: 00010006
      [  +0,005222] RAX: 0000000000000046 RBX: 00000000000005a0 RCX: 0000000000000001
      [  +0,007133] RDX: 000000000001b608 RSI: 0000000000000000 RDI: ffffffff82121972
      [  +0,007129] RBP: 0000000000000202 R08: 0000000000000000 R09: 0000000000000001
      [  +0,007129] R10: 0000000000000000 R11: 0000000000000000 R12: ffff88847bfa5096
      [  +0,007131] R13: 0000000000000010 R14: ffff88849c08f3f8 R15: 0000000000000000
      [  +0,007128] FS:  0000000000000000(0000) GS:ffff88849dc80000(0000) knlGS:0000000000000000
      [  +0,008083] CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
      [  +0,005749] CR2: 00000000000005a0 CR3: 0000000005210006 CR4: 0000000000760ee0
      [  +0,007128] PKRU: 55555554
      [  +0,002722] Call Trace:
      [  +0,002458]  drm_dp_mst_handle_up_req+0x517/0x540 [drm_kms_helper]
      [  +0,006197]  ? drm_dp_mst_hpd_irq+0x5b/0x9c0 [drm_kms_helper]
      [  +0,005764]  drm_dp_mst_hpd_irq+0x5b/0x9c0 [drm_kms_helper]
      [  +0,005623]  ? intel_dp_hpd_pulse+0x205/0x370 [i915]
      [  +0,005018]  intel_dp_hpd_pulse+0x205/0x370 [i915]
      [  +0,004836]  i915_digport_work_func+0xbb/0x140 [i915]
      [  +0,005108]  process_one_work+0x245/0x610
      [  +0,004027]  worker_thread+0x37/0x380
      [  +0,003684]  ? process_one_work+0x610/0x610
      [  +0,004184]  kthread+0x119/0x130
      [  +0,003240]  ? kthread_park+0x80/0x80
      [  +0,003668]  ret_from_fork+0x24/0x50
      
      Cc: Lyude Paul <lyude@redhat.com>
      Cc: Dave Airlie <airlied@redhat.com>
      Signed-off-by: default avatarImre Deak <imre.deak@intel.com>
      Reviewed-by: default avatarLyude Paul <lyude@redhat.com>
      Link: https://patchwork.freedesktop.org/patch/msgid/20190523212433.9058-1-imre.deak@intel.com
      d8fd3722
    • Andrey Grodzovsky's avatar