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-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJMQK-i1GFP_5NsH7MLYS17xacrYZf1u6bjVYBkW-qHMbuh2_w@mail.gmail.com>
Date:   Mon, 17 Oct 2022 21:48:37 +0800
From:   Hsin-Yi Wang <hsinyi@...omium.org>
To:     Douglas Anderson <dianders@...omium.org>,
        Sean Paul <seanpaul@...omium.org>
Cc:     Maarten Lankhorst <maarten.lankhorst@...ux.intel.com>,
        Maxime Ripard <mripard@...nel.org>,
        Thomas Zimmermann <tzimmermann@...e.de>,
        Daniel Vetter <daniel@...ll.ch>,
        dri-devel@...ts.freedesktop.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v2] drm_bridge: register content protect property

On Wed, Oct 12, 2022 at 12:20 PM Hsin-Yi Wang <hsinyi@...omium.org> wrote:
>
> Some bridges are able to update HDCP status from userspace request if
> they support HDCP.
>
> HDCP property is the same as other connector properties that need to be
> created after the connecter is initialized and before the connector is
> registered.
>
anx7625 is a user for this.


> Signed-off-by: Hsin-Yi Wang <hsinyi@...omium.org>
> Reported-by: kernel test robot <lkp@...el.com>
> ---
> v2: Fix compile error when config is not set.
> ---
>  drivers/gpu/drm/drm_bridge_connector.c | 3 +++
>  include/drm/display/drm_hdcp_helper.h  | 8 ++++++++
>  2 files changed, 11 insertions(+)
>
> diff --git a/drivers/gpu/drm/drm_bridge_connector.c b/drivers/gpu/drm/drm_bridge_connector.c
> index 1c7d936523df5..a3b9ef8dc3f0b 100644
> --- a/drivers/gpu/drm/drm_bridge_connector.c
> +++ b/drivers/gpu/drm/drm_bridge_connector.c
> @@ -7,6 +7,7 @@
>  #include <linux/module.h>
>  #include <linux/slab.h>
>
> +#include <drm/display/drm_hdcp_helper.h>
>  #include <drm/drm_atomic_state_helper.h>
>  #include <drm/drm_bridge.h>
>  #include <drm/drm_bridge_connector.h>
> @@ -398,6 +399,8 @@ struct drm_connector *drm_bridge_connector_init(struct drm_device *drm,
>         if (panel_bridge)
>                 drm_panel_bridge_set_orientation(connector, panel_bridge);
>
> +       drm_connector_attach_content_protection_property(connector, true);
> +
>         return connector;
>  }
>  EXPORT_SYMBOL_GPL(drm_bridge_connector_init);
> diff --git a/include/drm/display/drm_hdcp_helper.h b/include/drm/display/drm_hdcp_helper.h
> index 8aaf87bf27351..c65d9f06a2532 100644
> --- a/include/drm/display/drm_hdcp_helper.h
> +++ b/include/drm/display/drm_hdcp_helper.h
> @@ -15,8 +15,16 @@ struct drm_device;
>  struct drm_connector;
>
>  int drm_hdcp_check_ksvs_revoked(struct drm_device *dev, u8 *ksvs, u32 ksv_count);
> +#if defined(CONFIG_DRM_DISPLAY_HDCP_HELPER)
>  int drm_connector_attach_content_protection_property(struct drm_connector *connector,
>                                                      bool hdcp_content_type);
> +#else
> +static inline int drm_connector_attach_content_protection_property(struct drm_connector *connector,
> +                                                                  bool hdcp_content_type)
> +{
> +       return 0;
> +}
> +#endif
>  void drm_hdcp_update_content_protection(struct drm_connector *connector, u64 val);
>
>  #endif
> --
> 2.38.0.rc1.362.ged0d419d3c-goog
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ