1. 03 6月, 2021 5 次提交
  2. 20 5月, 2021 2 次提交
  3. 13 5月, 2021 1 次提交
  4. 05 5月, 2021 1 次提交
    • R
      drm/amd/display: Fix two cursor duplication when using overlay · 16e9b3e5
      Rodrigo Siqueira 提交于
      Our driver supports overlay planes, and as expected, some userspace
      compositor takes advantage of these features. If the userspace is not
      enabling the cursor, they can use multiple planes as they please.
      Nevertheless, we start to have constraints when userspace tries to
      enable hardware cursor with various planes. Basically, we cannot draw
      the cursor at the same size and position on two separated pipes since it
      uses extra bandwidth and DML only run with one cursor.
      
      For those reasons, when we enable hardware cursor and multiple planes,
      our driver should accept variations like the ones described below:
      
        +-------------+   +--------------+
        | +---------+ |   |              |
        | |Primary  | |   | Primary      |
        | |         | |   | Overlay      |
        | +---------+ |   |              |
        |Overlay      |   |              |
        +-------------+   +--------------+
      
      In this scenario, we can have the desktop UI in the overlay and some
      other framebuffer attached to the primary plane (e.g., video). However,
      userspace needs to obey some rules and avoid scenarios like the ones
      described below (when enabling hw cursor):
      
                                            +--------+
                                            |Overlay |
       +-------------+    +-----+-------+ +-|        |--+
       | +--------+  | +--------+       | | +--------+  |
       | |Overlay |  | |Overlay |       | |             |
       | |        |  | |        |       | |             |
       | +--------+  | +--------+       | |             |
       | Primary     |    | Primary     | | Primary     |
       +-------------+    +-------------+ +-------------+
      
       +-------------+   +-------------+
       |     +--------+  |  Primary    |
       |     |Overlay |  |             |
       |     |        |  |             |
       |     +--------+  | +--------+  |
       | Primary     |   | |Overlay |  |
       +-------------+   +-|        |--+
                           +--------+
      
      If the userspace violates some of the above scenarios, our driver needs
      to reject the commit; otherwise, we can have unexpected behavior. Since
      we don't have a proper driver validation for the above case, we can see
      some problems like a duplicate cursor in applications that use multiple
      planes. This commit fixes the cursor issue and others by adding adequate
      verification for multiple planes.
      
      Change since V1 (Harry and Sean):
      - Remove cursor verification from the equation.
      
      Cc: Louis Li <Ching-shih.Li@amd.com>
      Cc: Nicholas Kazlauskas <Nicholas.Kazlauskas@amd.com>
      Cc: Harry Wentland <Harry.Wentland@amd.com>
      Cc: Hersen Wu <hersenxs.wu@amd.com>
      Cc: Sean Paul <seanpaul@chromium.org>
      Signed-off-by: NRodrigo Siqueira <Rodrigo.Siqueira@amd.com>
      Reviewed-by: NHarry Wentland <harry.wentland@amd.com>
      Signed-off-by: NAlex Deucher <alexander.deucher@amd.com>
      16e9b3e5
  5. 29 4月, 2021 2 次提交
  6. 21 4月, 2021 19 次提交
  7. 16 4月, 2021 10 次提交