Re: [PATCH v3 1/1] drm/mediatek: Fix cursor plane didn't update

2021-07-21 Thread Sean Paul
On Tue, Jul 20, 2021 at 3:47 AM jason-jh.lin wrote: > > The cursor plane should use the current plane state hook in > atomic_async_update because it would not be the new plane state in > the global atomic state, since drm_atomic_helper_swap_state happened > when those plane state hook are run. > >

[RESEND PATCH v6 00/14] drm/trace: Mirror DRM debug logs to tracefs

2021-07-21 Thread Sean Paul
From: Sean Paul Hi all, I just had the pleasure of rebasing this set on our CrOS downstream kernel and wanted to resend it for consideration once again. There hasn't been any resistence to the set AFAIK, just perhaps not enough motivation for anyone to hit the go bit. There was some int

[RESEND PATCH v6 01/14] drm/mipi_dbi: Convert pr_debug calls to DRM_DEBUG_DRIVER

2021-07-21 Thread Sean Paul
From: Sean Paul Use the drm logging helpers to output these messages to ensure they'll be included by the drm tracefs instance. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-2-s...@poorly.run #v5 Changes in v5: -Added to the set Chang

[RESEND PATCH v6 02/14] drm/sil164: Convert dev_printk to drm_dev_dbg

2021-07-21 Thread Sean Paul
From: Sean Paul Use the drm debug helper instead of dev_printk in order to leverage the upcoming tracefs support Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-3-s...@poorly.run #v5 Changes in v5: -Added to the set Changes in v6: -None

[RESEND PATCH v6 03/14] drm/i915/utils: Replace dev_printk with drm helpers

2021-07-21 Thread Sean Paul
From: Sean Paul Use drm logging helpers to add support for the upcoming tracefs implementation. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-4-s...@poorly.run #v5 Changes in v5: -Added to the set Changes in v6: -None --- drivers/gpu/drm

[RESEND PATCH v6 04/14] drm/msm/dpu: Replace definitions for dpu debug macros

2021-07-21 Thread Sean Paul
From: Sean Paul The debug messages shouldn't be logged as errors when debug categories are enabled. Use the drm logging helpers to do the right thing Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-5-s...@poorly.run #v5 Changes in v5: -

[RESEND PATCH v6 05/14] drm/print: rename drm_debug* to be more syslog-centric

2021-07-21 Thread Sean Paul
From: Sean Paul In preparation for tracefs support, rename drm_debug related functions to reflect that it targets the syslog. This will allow us to selectively target syslog and/or tracefs. No functional changes here. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch

[RESEND PATCH v6 06/14] drm/amd: Gate i2c transaction logs on drm_debug_syslog

2021-07-21 Thread Sean Paul
From: Sean Paul Since the logs protected by these checks specifically target syslog, use the new drm_debug_syslog_enabled() call to avoid triggering these prints when only trace is enabled. Acked-by: Christian König Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid

[RESEND PATCH v6 07/14] drm/etnaviv: Change buffer dump checks to target syslog

2021-07-21 Thread Sean Paul
From: Sean Paul Since the logs protected by these checks specifically target syslog, use the new drm_debug_syslog_enabled() call to avoid triggering these prints when only trace is enabled. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-8-s

[RESEND PATCH v6 08/14] drm/nouveau: Change debug checks to specifically target syslog

2021-07-21 Thread Sean Paul
From: Sean Paul Since the logs protected by these checks specifically target syslog, use the new drm_debug_syslog_enabled() call to avoid triggering these prints when only trace is enabled. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-9-s

[RESEND PATCH v6 09/14] drm/i915: Change infoframe debug checks to specify syslog

2021-07-21 Thread Sean Paul
From: Sean Paul Since the logs protected by these checks specifically target syslog, use the new drm_debug_syslog_enabled() call to avoid triggering these prints when only trace is enabled. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-10-s

[RESEND PATCH v6 10/14] drm/print: Add drm_debug_category_printer

2021-07-21 Thread Sean Paul
From: Sean Paul This patch adds a new printer which will select the appropriate output for a given debug category. Currently there is only one output target, which is syslog. However in the future we'll have tracefs and it will be useful to print to syslog, tracefs, or both. Drivers just ne

[RESEND PATCH v6 11/14] drm/mst: Convert debug printers to debug category printers

2021-07-21 Thread Sean Paul
From: Sean Paul The printers in dp_mst are meant to be gated on DRM_UT_DP, so use the debug category printer to avoid dumping mst transactions to the wrong place. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-12-s...@poorly.run #v5 Changes

[RESEND PATCH v6 12/14] drm/i915: Use debug category printer for welcome message

2021-07-21 Thread Sean Paul
From: Sean Paul The welcome printer is meant to be gated on DRM_UT_DRIVER, so use the debug category printer to avoid dumping the message in the wrong place. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20200608210505.48519-13-s...@poorly.run #v5 Changes in

[RESEND PATCH v6 13/14] drm/atomic: Use debug category printer for atomic state printer

2021-07-21 Thread Sean Paul
From: Sean Paul The atomic state is printed if the DRM_UT_STATE is active, but it's printed at INFO level. This patch converts it to use the debug category printer so: a- it's consistent with other DRM_UT_STATE logging b- it's properly routed through drm_trace when introduced

[RESEND PATCH v6 14/14] drm/print: Add tracefs support to the drm logging helpers

2021-07-21 Thread Sean Paul
From: Sean Paul This patch adds a new module parameter called drm.trace which accepts the same mask as drm.debug. When a debug category is enabled, log messages will be put in a new tracefs instance called drm for consumption. Using the new tracefs instance will allow distros to enable drm

Re: [RESEND PATCH v6 00/14] drm/trace: Mirror DRM debug logs to tracefs

2021-07-22 Thread Sean Paul
On Thu, Jul 22, 2021 at 3:49 AM Pekka Paalanen wrote: > > On Wed, 21 Jul 2021 13:55:07 -0400 > Sean Paul wrote: > > > From: Sean Paul > > > > Hi all, > > I just had the pleasure of rebasing this set on our CrOS downstream > > kernel and wanted to res

Re: [RESEND PATCH v6 00/14] drm/trace: Mirror DRM debug logs to tracefs

2021-07-22 Thread Sean Paul
On Thu, Jul 22, 2021 at 9:48 AM Sean Paul wrote: > > On Thu, Jul 22, 2021 at 3:49 AM Pekka Paalanen wrote: > > > > On Wed, 21 Jul 2021 13:55:07 -0400 > > Sean Paul wrote: > > > > > From: Sean Paul > > > > > > Hi all, > > > I

Re: [Intel-gfx] [PATCH v3 3/5] drm/print: RFC add choice to use dynamic debug in drm-debug

2021-07-27 Thread Sean Paul
> void __drm_err(const char *format, ...); > > > > @@ -500,44 +545,45 @@ void __drm_err(const char *format, ...); > > #define DRM_ERROR_RATELIMITED(fmt, ...) > > \ > > DRM_DEV_ERROR_RATELIMITED(NULL, fmt, ##__VA_ARGS__) >

Re: [Intel-gfx] [PATCH v3 3/5] drm/print: RFC add choice to use dynamic debug in drm-debug

2021-07-27 Thread Sean Paul
On Thu, Jul 22, 2021 at 11:20 AM Sean Paul wrote: > Reply-all fail. Adding everyone else back to my response. > On Tue, Jul 20, 2021 at 03:29:34PM +0200, Daniel Vetter wrote: > > On Wed, Jul 14, 2021 at 11:51:36AM -0600, Jim Cromie wrote: > > > drm's debug system u

Re: [PATCH 0/6] drm/panel: atna33xc20: Fix the Samsung ATNA33XC20 panel

2021-07-29 Thread Sean Paul
; AMOLED panel and has a whole bunch of different components on board. > > [1] https://lore.kernel.org/r/20210723002146.1962910-1-diand...@chromium.org/ > > > Douglas Anderson (6): Hi Doug, Thanks for the patchset, it all looks to me. For all 6: Reviewed-by: Sean Paul Sean &g

Re: [PATCH 1/2] drm/mediatek: set panel orientation before drm_dev_register().

2021-04-23 Thread Sean Paul
On Fri, Apr 9, 2021 at 12:53 AM Hsin-Yi Wang wrote: > > drm_dev_register() sets connector->registration_state to > DRM_CONNECTOR_REGISTERED and dev->registered to true. If > drm_connector_set_panel_orientation() is first called after > drm_dev_register(), it will fail several checks and results in

Re: [PATCH v4 1/3] gpu: drm: separate panel orientation property creating and value setting

2021-04-28 Thread Sean Paul
On Wed, Apr 28, 2021 at 12:55 AM Hsin-Yi Wang wrote: > Thank you for revising the patchset, this looks much better to me! /snip > > diff --git a/drivers/gpu/drm/drm_connector.c b/drivers/gpu/drm/drm_connector.c > index 7631f76e7f34..cda83314d7ad 100644 > --- a/drivers/gpu/drm/drm_connector.c

Re: [PATCH v5 01/20] drm/panel: panel-simple: Add missing pm_runtime_disable() calls

2021-04-28 Thread Sean Paul
> them now. > > Fixes: 3235b0f20a0a ("drm/panel: panel-simple: Use runtime pm to avoid > excessive unprepare / prepare") > Reported-by: Bjorn Andersson Reviewed-by: Sean Paul > Signed-off-by: Douglas Anderson > --- > > Changes in v5: > - Missing pm_runtim

Re: [PATCH v5 10/20] drm/panel: panel-simple: Get rid of hacky HPD chicken-and-egg code

2021-04-28 Thread Sean Paul
iver to be a > collection of sub-drivers. Now the GPIO part can probe separately and > that breaks the chain. Let's get rid of the old code to clean things > up. > > Signed-off-by: Douglas Anderson > Reviewed-by: Bjorn Andersson Reviewed-by: Sean Paul > --- &

Re: [PATCH v5 16/20] drm/panel: panel-simple: Remove extra call: drm_connector_update_edid_property()

2021-04-28 Thread Sean Paul
in. > > Signed-off-by: Douglas Anderson > Reviewed-by: Bjorn Andersson Reviewed-by: Sean Paul > --- > As Laurent pointed out [1] this is actually a pretty common > problem. His suggestion to do this more broadly is a good idea but > this series is probably a bit ambitious alrea

Re: [PATCH v5 17/20] drm/panel: panel-simple: Power the panel when reading the EDID

2021-04-28 Thread Sean Paul
havior we can add a > per-panel flag. It appears that providing the DDC bus to the panel in > the past was somewhat uncommon in any case. > Maybe some combination of drivers caching the EDID for panels while they're already powered and overly broad pm runtime references? At any rate, th

Re: [PATCH v5 18/20] drm/panel: panel-simple: Cache the EDID as long as we retain power

2021-04-28 Thread Sean Paul
s(connector, p->edid); I suppose this would keep banging on the ddc if drm_get_edid() continuously returns NULL, but maybe that's desireable (it'll succeed sometime in the future)? At any rate, this is an improvement on current behavior so it has my vote. Reviewed-by: Sean Paul > >

Re: [PATCH v5 3/4] drm/i915: init panel orientation property

2021-04-28 Thread Sean Paul
On Wed, Apr 28, 2021 at 1:04 PM Hsin-Yi Wang wrote: > > Creating the panel orientation property first since we separate the > property creating and value setting. This should probably be included in patch 1 so you don't regress i915 in between patches. Sean > > Signed-off-by: Hsin-Yi Wang > --

Re: [PATCH v2] drm: Copy drm_wait_vblank to user before returning

2021-08-17 Thread Sean Paul
On Fri, Aug 13, 2021 at 11:48 AM Mark Yacoub wrote: > > Thanks for your review Michel! > @MAINTAINER, could you please strip the Change-Id when applying. > Thanks! Applied to drm-misc-fixes with the Change-Id removed. Thank you for your patch! Sean > > On Fri, Aug 13, 2021 at 3:33 AM Michel Dä

Re: [PATCH v6 4/5] drm/bridge: anx7625: add HDCP support

2021-03-25 Thread Sean Paul
On Fri, Mar 19, 2021 at 2:35 AM Xin Ji wrote: > > Add HDCP feature, enable HDCP function through chip internal key > and downstream's capability. > > Signed-off-by: Xin Ji > --- > drivers/gpu/drm/bridge/analogix/anx7625.c | 147 ++ > drivers/gpu/drm/bridge/analogix/anx7625.h

Re: [PATCH v6 4/5] drm/bridge: anx7625: add HDCP support

2021-03-29 Thread Sean Paul
On Mon, Mar 29, 2021 at 6:27 AM Xin Ji wrote: > > On Thu, Mar 25, 2021 at 02:19:23PM -0400, Sean Paul wrote: > > On Fri, Mar 19, 2021 at 2:35 AM Xin Ji wrote: > > > > > > Add HDCP feature, enable HDCP function through chip internal key > > > and downstream&

[PATCH v2] drm/i915/hdcp: Disable the QSES check for HDCP 1.4 over MST

2021-01-21 Thread Sean Paul
From: Sean Paul The HDCP 1.4 spec does not require the QUERY_STREAM_ENCRYPTION_STATUS check, it was always a nice-to-have. After deploying this across various devices, we've determined that some MST bridge chips do not properly support this call for HDCP 1.4 (namely Synaptics and Realtek

Re: [Freedreno] [PATCH v2 2/2] drm/msm/dp: add supported max link rate specified from dtsi

2021-02-22 Thread Sean Paul
On Mon, Feb 22, 2021 at 11:31 AM wrote: > > On 2021-02-19 14:46, Stephen Boyd wrote: > > Quoting khs...@codeaurora.org (2021-02-19 08:39:38) > >> On 2021-02-18 15:02, Stephen Boyd wrote: > >> > Quoting Kuogee Hsieh (2021-02-18 12:55:04) > >> >> Allow supported link rate to be limited to the value

[PATCH 1/2] drm/i915/dp_link_training: Add newlines to debug messages

2021-03-10 Thread Sean Paul
From: Sean Paul This patch adds some newlines which are missing from debug messages. This will prevent logs from being stacked up in dmesg. Signed-off-by: Sean Paul --- drivers/gpu/drm/i915/display/intel_dp_link_training.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git

[PATCH 2/2] drm/i915/dp_link_training: Convert DRM_DEBUG_KMS to drm_dbg_kms

2021-03-10 Thread Sean Paul
From: Sean Paul One instance of DRM_DEBUG_KMS was leftover in dp_link_training, convert it to the new shiny. Signed-off-by: Sean Paul --- .../gpu/drm/i915/display/intel_dp_link_training.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/gpu/drm/i915

[PATCH] drm/msm: Fix uninitialized var usage in dsi_phy_28nm_8960.c

2021-05-07 Thread Sean Paul
From: Sean Paul This patch fixes the following error: drivers/gpu/drm/msm/dsi/phy/dsi_phy_28nm_8960.c:425:11: error: variable 'parent_name' is uninitialized when used here [-Werror,-Wuninitialized] snprintf(parent_name, 32, "dsi%dvco_clk"

Re: [PATCH v6 1/3] gpu: drm: separate panel orientation property creating and value setting

2021-05-20 Thread Sean Paul
410 > [4.881711] drm_compat_ioctl+0xdc/0xf0 > [4.885536] __arm64_compat_sys_ioctl+0xc8/0x100 > [4.890142] el0_svc_common+0xf4/0x1c0 > [4.893879] do_el0_svc_compat+0x28/0x3c > [4.897791] el0_svc_compat+0x10/0x1c > [4.901441] el0_sync_compat_handler+0xa8/0xc

[PATCH] drm/i915/display/tc: Only WARN once for bogus tc port flag

2020-12-09 Thread Sean Paul
From: Sean Paul No need to spam syslog/console when we can ignore/fix the flag. Signed-off-by: Sean Paul --- drivers/gpu/drm/i915/display/intel_tc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_tc.c b/drivers/gpu/drm/i915/display

[PATCH] drm/msm/dp: Initialize dp->aux->drm_dev before registration

2021-07-14 Thread Sean Paul
From: Sean Paul Avoids the following WARN: [3.009556] [ cut here ] [3.014306] WARNING: CPU: 7 PID: 109 at drivers/gpu/drm/drm_dp_helper.c:1796 drm_dp_aux_register+0xa4/0xac [3.024209] Modules linked in: [3.027351] CPU: 7 PID: 109 Comm: kworker/7:8 Not

[PATCH] drm/amdgpu: Add support for drm_privacy_screen

2022-03-08 Thread Sean Paul
From: Sean Paul This patch adds the necessary hooks to make amdgpu aware of privacy screens. On devices with privacy screen drivers (such as thinkpad-acpi), the amdgpu driver will defer probe until it's ready and then sync the sw and hw state on each commit the connector is involved and en

[PATCH v2] drm/amdgpu: Add support for drm_privacy_screen

2022-03-09 Thread Sean Paul
From: Sean Paul This patch adds the necessary hooks to make amdgpu aware of privacy screens. On devices with privacy screen drivers (such as thinkpad-acpi), the amdgpu driver will defer probe until it's ready and then sync the sw and hw state on each commit the connector is involved and en

[PATCH] drm/amd: Re-classify some log messages in commit path

2022-03-24 Thread Sean Paul
From: Sean Paul ATOMIC and DRIVER log categories do not typically contain per-frame log messages. This patch re-classifies some messages in amd to chattier categories to keep ATOMIC/DRIVER quiet. Signed-off-by: Sean Paul --- drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 5 +++-- drivers

[PATCH 00/14] drm/hdcp: Pull HDCP auth/exchange/check into

2021-09-13 Thread Sean Paul
From: Sean Paul Hello, This patchset pulls the HDCP protocol auth/exchange/check logic out from i915 into a HDCP helper library which drivers can use to implement the proper protocol and UAPI interactions for achieving HDCP. Originally this was all stuffed into i915 since it was the only driver

[PATCH 01/14] drm/hdcp: Add drm_hdcp_atomic_check()

2021-09-13 Thread Sean Paul
From: Sean Paul This patch moves the hdcp atomic check from i915 to drm_hdcp so other drivers can use it. No functional changes, just cleaned up some of the code when moving it over. Signed-off-by: Sean Paul --- drivers/gpu/drm/drm_hdcp.c | 71 - drivers

[PATCH 02/14] drm/hdcp: Avoid changing crtc state in hdcp atomic check

2021-09-13 Thread Sean Paul
From: Sean Paul Instead of forcing a modeset in the hdcp atomic check, simply return true if the content protection value is changing and let the driver decide whether a modeset is required or not. Signed-off-by: Sean Paul --- drivers/gpu/drm/drm_hdcp.c | 33

[PATCH 03/14] drm/hdcp: Update property value on content type and user changes

2021-09-13 Thread Sean Paul
From: Sean Paul This patch updates the connector's property value in 2 cases which were previously missed: 1- Content type changes. The value should revert back to DESIRED from ENABLED in case the driver must re-authenticate the link due to the new content type. 2- Userspace sets

[PATCH 04/14] drm/hdcp: Expand HDCP helper library for enable/disable/check

2021-09-13 Thread Sean Paul
From: Sean Paul This patch expands upon the HDCP helper library to manage HDCP enable, disable, and check. Previous to this patch, the majority of the state management and sink interaction is tucked inside the Intel driver with the understanding that once a new platform supported HDCP we could

[PATCH 05/14] drm/i915/hdcp: Consolidate HDCP setup/state cache

2021-09-13 Thread Sean Paul
From: Sean Paul Stick all of the setup for HDCP into a dedicated function. No functional change, but this will facilitate moving HDCP logic into helpers. Signed-off-by: Sean Paul --- drivers/gpu/drm/i915/display/intel_hdcp.c | 52 +++ 1 file changed, 35 insertions(+), 17

[PATCH 06/14] drm/i915/hdcp: Retain hdcp_capable return codes

2021-09-13 Thread Sean Paul
From: Sean Paul The shim functions return error codes, but they are discarded in intel_hdcp.c. This patch plumbs the return codes through so they are properly handled. Signed-off-by: Sean Paul --- .../drm/i915/display/intel_display_debugfs.c | 9 +++- drivers/gpu/drm/i915/display

[PATCH 07/14] drm/i915/hdcp: Use HDCP helpers for i915

2021-09-13 Thread Sean Paul
From: Sean Paul Now that all of the HDCP 1.x logic has been migrated to the central HDCP helpers, use it in the i915 driver. The majority of the driver code for HDCP 1.x will live in intel_hdcp.c, however there are a few helper hooks which are connector-specific and need to be partially or

[PATCH 08/14] drm/msm/dpu_kms: Re-order dpu includes

2021-09-13 Thread Sean Paul
From: Sean Paul Make includes alphabetical in dpu_kms.c Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c b/drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c index

[PATCH 09/14] drm/msm/dpu: Remove useless checks in dpu_encoder

2021-09-13 Thread Sean Paul
From: Sean Paul A couple more useless checks to remove in dpu_encoder. Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 1 file changed, 12 deletions(-) diff --git a/drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c b/drivers/gpu/drm/msm/disp/dpu1

[PATCH 10/14] drm/msm/dpu: Remove encoder->enable() hack

2021-09-13 Thread Sean Paul
From: Sean Paul encoder->commit() was being misused because there were some global resources which needed to be tweaked in encoder->enable() which were not accessible in dpu_encoder.c. That is no longer true and the redirect serves no purpose any longer. So remove the indirection. Signed-

[PATCH 11/14] drm/msm/dp: Re-order dp_audio_put in deinit_sub_modules

2021-09-13 Thread Sean Paul
From: Sean Paul Audio is initialized last, it should be de-initialized first to match the order in dp_init_sub_modules(). Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/dp/dp_display.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/msm/dp/dp_display.c b

[PATCH 12/14] dt-bindings: msm/dp: Add bindings for HDCP registers

2021-09-13 Thread Sean Paul
From: Sean Paul This patch adds the bindings for the MSM DisplayPort HDCP registers which are required to write the HDCP key into the display controller as well as the registers to enable HDCP authentication/key exchange/encryption. Signed-off-by: Sean Paul --- .../bindings/display/msm/dp

[PATCH 13/14] drm/msm: Add hdcp register ranges to sc7180 device tree

2021-09-13 Thread Sean Paul
From: Sean Paul This patch adds the register ranges required for HDCP to the sc7180 device tree. These registers will be used to inject HDCP key as well as toggle HDCP on and off. Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/dp/dp_parser.c | 30 +++--- drivers/gpu

[PATCH 14/14] drm/msm: Implement HDCP 1.x using the new drm HDCP helpers

2021-09-13 Thread Sean Paul
From: Sean Paul This patch adds HDCP 1.x support to msm DP connectors using the new HDCP helpers. Signed-off-by: Sean Paul --- drivers/gpu/drm/msm/Makefile| 1 + drivers/gpu/drm/msm/dp/dp_debug.c | 49 +++- drivers/gpu/drm/msm/dp/dp_debug.h | 6 +- drivers/gpu/drm/msm/dp

Re: [PATCH 00/14] drm/hdcp: Pull HDCP auth/exchange/check into

2021-09-13 Thread Sean Paul
On Mon, Sep 13, 2021 at 2:05 PM Alex Deucher wrote: > > On Mon, Sep 13, 2021 at 1:57 PM Sean Paul wrote: > > > > From: Sean Paul > > > > Hello, > > This patchset pulls the HDCP protocol auth/exchange/check logic out from > > i915 into a HDCP helper libr

[PATCH v2 00/13] drm/hdcp: Pull HDCP auth/exchange/check into helpers

2021-09-15 Thread Sean Paul
From: Sean Paul Hello again, This is the second version of the HDCP helper patchset. See version 1 here: https://patchwork.freedesktop.org/series/94623/ In this second version, I've fixed up the oopsies exposed by 0-day and yamllint and incorporated early review feedback from the dt/dts re

[PATCH v2 01/13] drm/hdcp: Add drm_hdcp_atomic_check()

2021-09-15 Thread Sean Paul
From: Sean Paul This patch moves the hdcp atomic check from i915 to drm_hdcp so other drivers can use it. No functional changes, just cleaned up some of the code when moving it over. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-2-s

[PATCH v2 02/13] drm/hdcp: Avoid changing crtc state in hdcp atomic check

2021-09-15 Thread Sean Paul
From: Sean Paul Instead of forcing a modeset in the hdcp atomic check, simply return true if the content protection value is changing and let the driver decide whether a modeset is required or not. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid

[PATCH v2 03/13] drm/hdcp: Update property value on content type and user changes

2021-09-15 Thread Sean Paul
From: Sean Paul This patch updates the connector's property value in 2 cases which were previously missed: 1- Content type changes. The value should revert back to DESIRED from ENABLED in case the driver must re-authenticate the link due to the new content type. 2- Userspace sets

[PATCH v2 04/13] drm/hdcp: Expand HDCP helper library for enable/disable/check

2021-09-15 Thread Sean Paul
From: Sean Paul This patch expands upon the HDCP helper library to manage HDCP enable, disable, and check. Previous to this patch, the majority of the state management and sink interaction is tucked inside the Intel driver with the understanding that once a new platform supported HDCP we could

[PATCH v2 05/13] drm/i915/hdcp: Consolidate HDCP setup/state cache

2021-09-15 Thread Sean Paul
From: Sean Paul Stick all of the setup for HDCP into a dedicated function. No functional change, but this will facilitate moving HDCP logic into helpers. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-6-s...@poorly.run #v1 Changes in v2

[PATCH v2 06/13] drm/i915/hdcp: Retain hdcp_capable return codes

2021-09-15 Thread Sean Paul
From: Sean Paul The shim functions return error codes, but they are discarded in intel_hdcp.c. This patch plumbs the return codes through so they are properly handled. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-7-s...@poorly.run #v1

[PATCH v2 07/13] drm/i915/hdcp: Use HDCP helpers for i915

2021-09-15 Thread Sean Paul
From: Sean Paul Now that all of the HDCP 1.x logic has been migrated to the central HDCP helpers, use it in the i915 driver. The majority of the driver code for HDCP 1.x will live in intel_hdcp.c, however there are a few helper hooks which are connector-specific and need to be partially or

[PATCH v2 08/13] drm/msm/dpu_kms: Re-order dpu includes

2021-09-15 Thread Sean Paul
From: Sean Paul Make includes alphabetical in dpu_kms.c Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-9-s...@poorly.run #v1 Changes in v2: -None --- drivers/gpu/drm/msm/disp/dpu1/dpu_kms.c | 8 1 file changed, 4 insertions(+), 4

[PATCH v2 09/13] drm/msm/dpu: Remove useless checks in dpu_encoder

2021-09-15 Thread Sean Paul
From: Sean Paul A couple more useless checks to remove in dpu_encoder. Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-10-s...@poorly.run #v1 Changes in v2: -None --- drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 12 1 file

[PATCH v2 10/13] drm/msm/dpu: Remove encoder->enable() hack

2021-09-15 Thread Sean Paul
From: Sean Paul encoder->commit() was being misused because there were some global resources which needed to be tweaked in encoder->enable() which were not accessible in dpu_encoder.c. That is no longer true and the redirect serves no purpose any longer. So remove the indirection. Signed-

[PATCH v2 11/13] drm/msm/dp: Re-order dp_audio_put in deinit_sub_modules

2021-09-15 Thread Sean Paul
From: Sean Paul Audio is initialized last, it should be de-initialized first to match the order in dp_init_sub_modules(). Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-12-s...@poorly.run #v1 Changes in v2: -None --- drivers/gpu/drm/msm/dp

[PATCH v2 12/13] dt-bindings: msm/dp: Add bindings for HDCP registers

2021-09-15 Thread Sean Paul
From: Sean Paul This patch adds the bindings for the MSM DisplayPort HDCP registers which are required to write the HDCP key into the display controller as well as the registers to enable HDCP authentication/key exchange/encryption. Cc: Rob Herring Cc: Stephen Boyd Signed-off-by: Sean Paul

[PATCH v2 13/13] drm/msm: Implement HDCP 1.x using the new drm HDCP helpers

2021-09-15 Thread Sean Paul
From: Sean Paul This patch adds HDCP 1.x support to msm DP connectors using the new HDCP helpers. Cc: Stephen Boyd Signed-off-by: Sean Paul Link: https://patchwork.freedesktop.org/patch/msgid/20210913175747.47456-15-s...@poorly.run #v1 Changes in v2: -Squash [1] into this patch with the

Re: [PATCH 01/15] dmr: cleanup: drm_modeset_lock_all_ctx() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
ient_firmware_config(struct > drm_client_dev *client, > ret = false; > } > > - drm_modeset_drop_locks(&ctx); > - drm_modeset_acquire_fini(&ctx); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, err); > > kfree(save_enabled); > return ret; > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 03/15] dmr/msm: cleanup: drm_modeset_lock_all_ctx() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
), Reviewed-by: Sean Paul > Signed-off-by: Fernando Ramos > --- > drivers/gpu/drm/msm/disp/msm_disp_snapshot_util.c | 10 -- > 1 file changed, 4 insertions(+), 6 deletions(-) > > diff --git a/drivers/gpu/drm/msm/disp/msm_disp_snapshot_util.c > b/drivers/gpu/drm/

Re: [PATCH 02/15] dmr/i915: cleanup: drm_modeset_lock_all_ctx() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
), Reviewed-by: Sean Paul > Signed-off-by: Fernando Ramos > --- > drivers/gpu/drm/i915/display/intel_display.c | 17 - > 1 file changed, 4 insertions(+), 13 deletions(-) > > diff --git a/drivers/gpu/drm/i915/display/intel_display.c > b/drivers/gpu/drm/i91

Re: [PATCH 04/15] drm: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
On Thu, Sep 16, 2021 at 11:15:41PM +0200, Fernando Ramos wrote: > As requested in Documentation/gpu/todo.rst, replace driver calls to > drm_modeset_lock_all() with DRM_MODESET_LOCK_ALL_BEGIN() and > DRM_MODESET_LOCK_ALL_END() > > Signed-off-by: Fernando Ramos Reviewe

Re: [PATCH 05/15] drm/vmwgfx: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
On Thu, Sep 16, 2021 at 11:15:42PM +0200, Fernando Ramos wrote: > As requested in Documentation/gpu/todo.rst, replace driver calls to > drm_modeset_lock_all() with DRM_MODESET_LOCK_ALL_BEGIN() and > DRM_MODESET_LOCK_ALL_END() > Reviewed-by: Sean Paul > Signed-off-by:

Re: [PATCH 06/15] drm/tegra: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
ut.encoder.crtc; > struct drm_device *drm = node->minor->dev; > + struct drm_modeset_acquire_ctx ctx; > unsigned int i; > int err = 0; > + int ret; You can use err here instead. With that fixed, Reviewed-by: Sean Paul > > - drm_modes

Re: [PATCH 07/15] drm/shmobile: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
On Thu, Sep 16, 2021 at 11:15:44PM +0200, Fernando Ramos wrote: > As requested in Documentation/gpu/todo.rst, replace driver calls to > drm_modeset_lock_all() with DRM_MODESET_LOCK_ALL_BEGIN() and > DRM_MODESET_LOCK_ALL_END() > > Signed-off-by: Fernando Ramos Reviewe

Re: [PATCH 08/15] drm/radeon: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
59,7 +762,7 @@ static int radeon_debugfs_mst_info_show(struct seq_file > *m, void *unused) > radeon_connector->cur_stream_attribs[i].fe, > > radeon_connector->cur_stream_attribs[i].slots); > } > - drm_modeset_unlock_all(dev); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); > return 0; > } > > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 09/15] drm/omapdrm: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
x; > + int ret; > > - drm_modeset_lock_all(fb->dev); > + DRM_MODESET_LOCK_ALL_BEGIN(fb->dev, ctx, 0, ret); > > drm_for_each_crtc(crtc, fb->dev) > omap_crtc_flush(crtc); > > - drm_modeset_unlock_all(fb->dev); > + DRM_MODESET_LOCK_ALL_END(fb-&g

Re: [PATCH 09/15] drm/omapdrm: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
x; > + int ret; > > - drm_modeset_lock_all(fb->dev); > + DRM_MODESET_LOCK_ALL_BEGIN(fb->dev, ctx, 0, ret); > > drm_for_each_crtc(crtc, fb->dev) > omap_crtc_flush(crtc); > > - drm_modeset_unlock_all(fb->dev); > + DRM_MODESET_LOCK_

Re: [PATCH 10/15] drm/nouveau: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
; > + DRM_MODESET_LOCK_ALL_BEGIN(drm_dev, ctx, 0, ret); > acomp->ops = &nv50_audio_component_ops; > acomp->dev = kdev; > drm->audio.component = acomp; > - drm_modeset_unlock_all(drm_dev); > + DRM_MODESET_LOCK_ALL_END(drm_dev, ctx, ret);

Re: [PATCH 11/15] drm/msm: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
e *s, > void *data) > dpu_crtc->vblank_cb_time = ktime_set(0, 0); > } > > - drm_modeset_unlock_all(crtc->dev); > + DRM_MODESET_LOCK_ALL_END(crtc->dev, ctx, ret); > > return 0; Return ret here > } > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 12/15] drm/i915: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
+ DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); > > return ret; > } > diff --git a/drivers/gpu/drm/i915/i915_drv.c b/drivers/gpu/drm/i915/i915_drv.c > index 59fb4c710c8c..7a30e2ff2fed 100644 > --- a/drivers/gpu/drm/i915/i915_drv.c > +++ b/drivers/gpu/drm/i915/i915_drv.c > @@ -1009,31 +1009,35 @@ static void i915_driver_postclose(struct drm_device > *dev, struct drm_file *file) > static void intel_suspend_encoders(struct drm_i915_private *dev_priv) > { > struct drm_device *dev = &dev_priv->drm; > + struct drm_modeset_acquire_ctx ctx; > struct intel_encoder *encoder; > + int ret; > > if (!HAS_DISPLAY(dev_priv)) > return; > > - drm_modeset_lock_all(dev); > + DRM_MODESET_LOCK_ALL_BEGIN(dev, ctx, 0, ret); > for_each_intel_encoder(dev, encoder) > if (encoder->suspend) > encoder->suspend(encoder); > - drm_modeset_unlock_all(dev); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); > } > > static void intel_shutdown_encoders(struct drm_i915_private *dev_priv) > { > struct drm_device *dev = &dev_priv->drm; > + struct drm_modeset_acquire_ctx ctx; > struct intel_encoder *encoder; > + int ret; > > if (!HAS_DISPLAY(dev_priv)) > return; > > - drm_modeset_lock_all(dev); > + DRM_MODESET_LOCK_ALL_BEGIN(dev, ctx, 0, ret); > for_each_intel_encoder(dev, encoder) > if (encoder->shutdown) > encoder->shutdown(encoder); > - drm_modeset_unlock_all(dev); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); > } > > void i915_driver_shutdown(struct drm_i915_private *i915) > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 13/15] drm/gma500: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
> list_for_each_entry(crtc, &dev->mode_config.crtc_list, head) > if (drm_helper_crtc_in_use(crtc)) > dev_priv->ops->restore_crtc(crtc); > @@ -232,7 +238,7 @@ static int psb_restore_display_registers(struct > drm_device *dev) > if (connector->restore) > connector->restore(&connector->base); > > - drm_modeset_unlock_all(dev); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); > return 0; Here too > } > > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 14/15] drm/amd: cleanup: drm_modeset_lock_all() --> DRM_MODESET_LOCK_ALL_BEGIN()

2021-09-17 Thread Sean Paul
modeset_lock_all(dev); > - dm_restore_drm_connector_state(dev, connector); > - drm_modeset_unlock_all(dev); > - > - drm_kms_helper_hotplug_event(dev); > } else if (param[0] == 0) { > if (!aconnector->dc_link) > goto unlock; > @@ -1259,13 +1257,16 @@ static ssize_t trigger_hotplug(struct file *f, const > char __user *buf, > > amdgpu_dm_update_connector_after_detect(aconnector); > > - drm_modeset_lock_all(dev); > - dm_restore_drm_connector_state(dev, connector); > - drm_modeset_unlock_all(dev); > - > - drm_kms_helper_hotplug_event(dev); > + } else { > + goto unlock; > } > > + DRM_MODESET_LOCK_ALL_BEGIN(dev, ctx, 0, ret); > + dm_restore_drm_connector_state(dev, connector); > + DRM_MODESET_LOCK_ALL_END(dev, ctx, ret); Check ret here? > + > + drm_kms_helper_hotplug_event(dev); > + > unlock: > mutex_unlock(&aconnector->hpd_lock); > > -- > 2.33.0 > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH 15/15] doc: drm: remove TODO entry regarding DRM_MODSET_LOCK_ALL cleanup

2021-09-17 Thread Sean Paul
x27;s queue that up as part of the set. Reviewed-by: Sean Paul > > Signed-off-by: Fernando Ramos > --- > Documentation/gpu/todo.rst| 17 - > Documentation/locking/ww-mutex-design.rst | 2 +- > 2 files changed, 1 insertion(+), 18 deletions(-) &g

Re: [PATCH 2/2] amd/amdgpu_dm: Verify Gamma and Degamma LUT sizes using DRM Core check

2021-10-14 Thread Sean Paul
erify LUT sizes and use DRM Core function > instead. > > Tested on ChromeOS Zork. > > v1: > Remove amdgpu_dm_verify_lut_sizes everywhere. > Reviewed-by: Sean Paul > Signed-off-by: Mark Yacoub > --- > .../gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 8 ++--- > ...

Re: [PATCH] MAINTAINERS: Fixup drm-misc website link

2021-10-19 Thread Sean Paul
that out. > Nice catch! Reviewed-by: Sean Paul (fwiw) > Signed-off-by: Brian Norris > --- > > MAINTAINERS | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/MAINTAINERS b/MAINTAINERS > index 100d7f93a15b..811d8d3e35fb 100644 > --- a/MAIN

Re: [PATCH] drm/bridge: analogix_dp: Make PSR-disable non-blocking

2021-10-20 Thread Sean Paul
. This also brings behavior in line with the > downstream ("mainline-derived") variant of the driver currently deployed > to Chrome OS Rockchip systems. > > Tested on a Samsung Chromebook Plus (i.e., Rockchip RK3399 Gru Kevin). > > Fixes: 6c836d965bad ("drm/rockchi

Re: [PATCH] drm/mediatek: Set Rotation default value to 1.

2021-10-25 Thread Sean Paul
diatek/mtk_drm_plane.c > b/drivers/gpu/drm/mediatek/mtk_drm_plane.c > index e6dcb34d30522..accd26481b9fb 100644 > --- a/drivers/gpu/drm/mediatek/mtk_drm_plane.c > +++ b/drivers/gpu/drm/mediatek/mtk_drm_plane.c > @@ -44,9 +44,10 @@ static void mtk_plane_reset(struct drm_plane *plane) > stat

Re: [PATCH] mediatek: Set default value for Panel Orientation connector prop.

2021-10-25 Thread Sean Paul
MAL right after creating > the prop. Reviewed-by: Sean Paul > > Tested on Jacuzzi(MTK) > Fixes IGT@kms_properties@get_properties-sanity-{atomic,non-atomic} > > Signed-off-by: Mark Yacoub > --- > drivers/gpu/drm/mediatek/mtk_dsi.c | 2 ++ > 1 file changed, 2 inser

Re: [Intel-gfx] [PATCH 1/2] drm: Add Gamma and Degamma LUT sizes props to drm_crtc to validate.

2021-10-25 Thread Sean Paul
; DRM_COLOR_LUT_NON_DECREASING = BIT(1), > }; > > -int drm_color_lut_check(const struct drm_property_blob *lut, u32 tests); > +int drm_color_lut_channels_check(const struct drm_property_blob *lut, > + u32 tests); > #endif > diff --git a/include/drm/drm_crtc.h b/include/drm/drm_crtc.h > index 2deb15d7e1610..cabd3ef1a6e32 100644 > --- a/include/drm/drm_crtc.h > +++ b/include/drm/drm_crtc.h > @@ -1072,6 +1072,17 @@ struct drm_crtc { > /** @funcs: CRTC control functions */ > const struct drm_crtc_funcs *funcs; > > + /** > + * @degamma_lut_size: Size of degamma LUT. > + */ > + uint32_t degamma_lut_size; > + > + /** > + * @gamma_lut_size: Size of Gamma LUT. Not used by legacy userspace > such as > + * X, which doesn't support large lut sizes. > + */ > + uint32_t gamma_lut_size; > + > /** >* @gamma_size: Size of legacy gamma ramp reported to userspace. Set up >* by calling drm_mode_crtc_set_gamma_size(). > -- > 2.33.0.882.g93a45727a2-goog > -- Sean Paul, Software Engineer, Google / Chromium OS

Re: [PATCH] drm/mediatek: Set Rotation default value to 1.

2021-10-25 Thread Sean Paul
On Mon, Oct 25, 2021 at 09:11:54PM -0400, Sean Paul wrote: > On Fri, Oct 22, 2021 at 12:54:02PM -0400, Mark Yacoub wrote: > > From: Mark Yacoub > > > > [Why] > > The Rotation prob is a bitmask value. It must always have a valid value. > > nit: s/prob/prop/ >

Re: [PATCH v2 10/13] drm/msm/dpu: Remove encoder->enable() hack

2021-09-17 Thread Sean Paul
On Thu, Sep 16, 2021 at 08:53:50PM -0700, Stephen Boyd wrote: > Quoting Sean Paul (2021-09-15 13:38:29) > > From: Sean Paul > > > > encoder->commit() was being misused because there were some global > > resources which needed to be tweaked in encoder->enable()

Re: [PATCH v2 13/13] drm/msm: Implement HDCP 1.x using the new drm HDCP helpers

2021-09-17 Thread Sean Paul
On Thu, Sep 16, 2021 at 11:00:25PM -0700, Stephen Boyd wrote: > Quoting Sean Paul (2021-09-15 13:38:32) /snip > > diff --git a/drivers/gpu/drm/msm/dp/dp_debug.c > > b/drivers/gpu/drm/msm/dp/dp_debug.c > > index 2f6247e80e9d..de16fca8782a 100644 > > --- a/driver

Re: [Freedreno] [PATCH v2 04/13] drm/hdcp: Expand HDCP helper library for enable/disable/check

2021-09-28 Thread Sean Paul
On Tue, Sep 21, 2021 at 04:34:59PM -0700, abhin...@codeaurora.org wrote: > On 2021-09-15 13:38, Sean Paul wrote: > > From: Sean Paul > > > > This patch expands upon the HDCP helper library to manage HDCP > > enable, disable, and check. > > > > Previous t

Re: [Freedreno] [PATCH v2 13/13] drm/msm: Implement HDCP 1.x using the new drm HDCP helpers

2021-09-28 Thread Sean Paul
On Tue, Sep 21, 2021 at 07:25:41PM -0700, abhin...@codeaurora.org wrote: > On 2021-09-15 13:38, Sean Paul wrote: > > From: Sean Paul > > > > This patch adds HDCP 1.x support to msm DP connectors using the new HDCP > > helpers. > > > > Cc: Stephen Boyd

  1   2   3   4   5   6   7   8   9   10   >