From: "Nautiyal, Ankit K" <ankit.k.nautiyal@intel.com>
To: Suraj Kandpal <suraj.kandpal@intel.com>,
<intel-gfx@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH 3/3] drm/i915/hdcp: Add more conditions to enable hdcp
Date: Fri, 27 Oct 2023 11:28:21 +0530 [thread overview]
Message-ID: <cb50dff2-fbc2-7941-e04c-4a2b82981eae@intel.com> (raw)
In-Reply-To: <20231026121139.987437-4-suraj.kandpal@intel.com>
On 10/26/2023 5:41 PM, Suraj Kandpal wrote:
> When we dock a monitor we end up with a enable and disable connector
> cycle but if hdcp content is running we get the userspace in
I was wondering if there should have been a uevent sent when driver
changes the state from enabled to undesired,
but as per documentation we send the uevent only from enabled->desired
or desired->enabled.
Anyway, this change looks good to me.
> enabled state and driver maintaining a undesired state which causes
> the content to stop playing and we only enabe hdcp if the userspace
Nitpick : enable
> state in desired. This patch fixes that.
>
> --v2
> -Move code to intel_hdcp [Jani]
>
> Signed-off-by: Suraj Kandpal <suraj.kandpal@intel.com>
Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_hdcp.c | 14 ++++++++++++--
> 1 file changed, 12 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_hdcp.c b/drivers/gpu/drm/i915/display/intel_hdcp.c
> index 44c0a93f3af8..39b3f7c0c77c 100644
> --- a/drivers/gpu/drm/i915/display/intel_hdcp.c
> +++ b/drivers/gpu/drm/i915/display/intel_hdcp.c
> @@ -2409,9 +2409,19 @@ void intel_hdcp_enable(struct intel_atomic_state *state,
> const struct intel_crtc_state *crtc_state,
> const struct drm_connector_state *conn_state)
> {
> - /* Enable hdcp if it's desired */
> + struct intel_connector *connector =
> + to_intel_connector(conn_state->connector);
> + struct intel_hdcp *hdcp = &connector->hdcp;
> +
> + /*
> + * Enable hdcp if it's desired or if userspace is enabled and
> + * driver set its state to undesired
> + */
> if (conn_state->content_protection ==
> - DRM_MODE_CONTENT_PROTECTION_DESIRED)
> + DRM_MODE_CONTENT_PROTECTION_DESIRED ||
> + (conn_state->content_protection ==
> + DRM_MODE_CONTENT_PROTECTION_ENABLED && hdcp->value ==
> + DRM_MODE_CONTENT_PROTECTION_UNDESIRED))
> _intel_hdcp_enable(state, encoder, crtc_state, conn_state);
> }
>
next prev parent reply other threads:[~2023-10-27 5:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-26 12:11 [Intel-gfx] [PATCH 0/3] drm/i915/hdcp: Additional conditions to enable hdcp Suraj Kandpal
2023-10-26 12:11 ` [Intel-gfx] [PATCH 1/3] drm/i915/hdcp: Rename HCDP 1.4 enablement function Suraj Kandpal
2023-10-26 12:36 ` Jani Nikula
2023-10-26 12:11 ` [Intel-gfx] [PATCH 2/3] drm/i915/hdcp: Convert intel_hdcp_enable to a blanket function Suraj Kandpal
2023-10-26 12:36 ` Jani Nikula
2023-10-26 12:11 ` [Intel-gfx] [PATCH 3/3] drm/i915/hdcp: Add more conditions to enable hdcp Suraj Kandpal
2023-10-27 5:58 ` Nautiyal, Ankit K [this message]
2023-10-27 3:35 ` [Intel-gfx] ✗ Fi.CI.SPARSE: warning for drm/i915/hdcp: Additional conditions to enable hdcp (rev4) Patchwork
2023-10-27 3:47 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2023-10-28 10:03 ` [Intel-gfx] ✗ Fi.CI.IGT: failure " Patchwork
2023-10-30 6:12 ` [Intel-gfx] ✓ Fi.CI.IGT: success " Patchwork
2023-10-31 11:04 ` [Intel-gfx] [PATCH 0/3] drm/i915/hdcp: Additional conditions to enable hdcp Nautiyal, Ankit K
-- strict thread matches above, loose matches on Subject: below --
2023-10-26 9:36 Suraj Kandpal
2023-10-26 9:36 ` [Intel-gfx] [PATCH 3/3] drm/i915/hdcp: Add more " Suraj Kandpal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cb50dff2-fbc2-7941-e04c-4a2b82981eae@intel.com \
--to=ankit.k.nautiyal@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=suraj.kandpal@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox