lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 26 Sep 2019 18:51:02 -0400
From:   Lyude Paul <lyude@...hat.com>
To:     amd-gfx@...ts.freedesktop.org
Cc:     "Daniel Vetter" <daniel@...ll.ch>,
        "Alex Deucher" <alexander.deucher@....com>,
        "Leo Li" <sunpeng.li@....com>, "David Airlie" <airlied@...ux.ie>,
        Christian König <christian.koenig@....com>,
        "David Francis" <david.francis@....com>,
        linux-kernel@...r.kernel.org, dri-devel@...ts.freedesktop.org,
        "David (ChunMing) Zhou" <david1.zhou@....com>,
        "Jerry (Fangzhi) Zuo" <jerry.zuo@....com>,
        "Harry Wentland" <harry.wentland@....com>,
        "Thomas Lim" <thomas.lim@....com>, "Lyude Paul" <lyude@...hat.com>,
        "Mario Kleiner" <mario.kleiner.de@...il.com>,
        "Nicholas Kazlauskas" <nicholas.kazlauskas@....com>,
        "Dingchen Zhang" <dingchen.zhang@....com>,
        "Brajeswar Ghosh" <brajeswar.linux@...il.com>,
        "Sam Ravnborg" <sam@...nborg.org>,
        "Maarten Lankhorst" <maarten.lankhorst@...ux.intel.com>,
        "Sean Paul" <sean@...rly.run>, "Maxime Ripard" <mripard@...nel.org>
Subject: [PATCH 0/6] drm/amdgpu: Fix incorrect encoder API usages

Noticed this while trying to respin my MST suspend/resume patch series.
It's not technically possible (at least until someone moves amdgpu
away from the deprecated drm_device->driver->{load,unload} hooks) for
amdgpu to properly register all of it's encoders before registering with
userspace. However, amdgpu also apparently adds and removes encoders
along with MST connectors - which is a much bigger issue as userspace
applications definitely do not expect this type of behavior.

So, let's fix it and add some WARNs() so new drivers don't accidentally
make this mistake in the future.

Lyude Paul (6):
  drm/amdgpu/dm/mst: Don't create MST topology managers for eDP ports
  drm/amdgpu/dm/mst: Remove unnecessary NULL check
  drm/amdgpu/dm/mst: Use ->atomic_best_encoder
  drm/amdgpu/dm/mst: Make MST encoders per-CRTC and fix encoder usage
  drm/amdgpu/dm/mst: Report possible_crtcs incorrectly, for now
  drm/encoder: WARN() when adding/removing encoders after device
    registration

 drivers/gpu/drm/amd/amdgpu/amdgpu_mode.h      |  3 ++
 .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 15 ++++++
 .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.h |  1 -
 .../display/amdgpu_dm/amdgpu_dm_mst_types.c   | 46 ++++++++++---------
 .../display/amdgpu_dm/amdgpu_dm_mst_types.h   |  3 ++
 drivers/gpu/drm/drm_encoder.c                 | 31 ++++++++++---
 6 files changed, 70 insertions(+), 29 deletions(-)

-- 
2.21.0

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ