2021-03-18 06:47:19

by Parshuram Raju Thombare

[permalink] [raw]
Subject: [PATCH v4 0/2] enable HDCP in Cadence MHDP bridge driver

This patch series enables HDCP in Cadence MHDP DPI/DP bridge driver.

Changes since v1:
- Move sapb reg block right after apb reg block
- Corresponding changes in binding and example

Changes since v2:
- Revert reg resource sequence in binding and
use resource mapping by name
- Remove hdcp_config from binding and use
DRM HDCP Content Type property to select
HDCP version

Changes since v3:
- Fix kernel test robot warning

Parshuram Thombare (2):
dt-bindings: drm/bridge: MHDP8546 bridge binding changes for HDCP
drm: bridge: cdns-mhdp8546: Enable HDCP

.../display/bridge/cdns,mhdp8546.yaml | 24 +-
drivers/gpu/drm/bridge/cadence/Makefile | 2 +-
.../drm/bridge/cadence/cdns-mhdp8546-core.c | 113 +++-
.../drm/bridge/cadence/cdns-mhdp8546-core.h | 21 +
.../drm/bridge/cadence/cdns-mhdp8546-hdcp.c | 570 ++++++++++++++++++
.../drm/bridge/cadence/cdns-mhdp8546-hdcp.h | 92 +++
6 files changed, 799 insertions(+), 23 deletions(-)
create mode 100644 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.c
create mode 100644 drivers/gpu/drm/bridge/cadence/cdns-mhdp8546-hdcp.h

--
2.25.1


2021-03-18 06:49:31

by Parshuram Raju Thombare

[permalink] [raw]
Subject: [PATCH v4 1/2] dt-bindings: drm/bridge: MHDP8546 bridge binding changes for HDCP

Add binding changes for HDCP in the MHDP8546 DPI/DP bridge binding.

Signed-off-by: Parshuram Thombare <[email protected]>
---
.../display/bridge/cdns,mhdp8546.yaml | 24 +++++++++++--------
1 file changed, 14 insertions(+), 10 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml b/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
index 63427878715e..8a85768f6202 100644
--- a/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
+++ b/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
@@ -17,8 +17,8 @@ properties:
- ti,j721e-mhdp8546

reg:
- minItems: 1
- maxItems: 2
+ minItems: 2
+ maxItems: 3
items:
- description:
Register block of mhdptx apb registers up to PHY mapped area (AUX_CONFIG_P).
@@ -26,13 +26,16 @@ properties:
included in the associated PHY.
- description:
Register block for DSS_EDP0_INTG_CFG_VP registers in case of TI J7 SoCs.
+ - description:
+ Register block of mhdptx sapb registers.

reg-names:
- minItems: 1
- maxItems: 2
+ minItems: 2
+ maxItems: 3
items:
- const: mhdptx
- const: j721e-intg
+ - const: mhdptx-sapb

clocks:
maxItems: 1
@@ -98,15 +101,15 @@ allOf:
then:
properties:
reg:
- minItems: 2
+ minItems: 3
reg-names:
- minItems: 2
+ minItems: 3
else:
properties:
reg:
- maxItems: 1
+ maxItems: 2
reg-names:
- maxItems: 1
+ maxItems: 2

required:
- compatible
@@ -129,8 +132,9 @@ examples:

mhdp: dp-bridge@f0fb000000 {
compatible = "cdns,mhdp8546";
- reg = <0xf0 0xfb000000 0x0 0x1000000>;
- reg-names = "mhdptx";
+ reg = <0xf0 0xfb000000 0x0 0x1000000>,
+ <0x0 0x4f48000 0x0 0x74>;
+ reg-names = "mhdptx", "mhdptx-sapb";
clocks = <&mhdp_clock>;
phys = <&dp_phy>;
phy-names = "dpphy";
--
2.25.1

2021-03-18 23:28:16

by Laurent Pinchart

[permalink] [raw]
Subject: Re: [PATCH v4 1/2] dt-bindings: drm/bridge: MHDP8546 bridge binding changes for HDCP

Hi Parshuram,

Thank you for the patch.

On Thu, Mar 18, 2021 at 07:45:30AM +0100, Parshuram Thombare wrote:
> Add binding changes for HDCP in the MHDP8546 DPI/DP bridge binding.
>
> Signed-off-by: Parshuram Thombare <[email protected]>
> ---
> .../display/bridge/cdns,mhdp8546.yaml | 24 +++++++++++--------
> 1 file changed, 14 insertions(+), 10 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml b/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
> index 63427878715e..8a85768f6202 100644
> --- a/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
> +++ b/Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml
> @@ -17,8 +17,8 @@ properties:
> - ti,j721e-mhdp8546
>
> reg:
> - minItems: 1
> - maxItems: 2
> + minItems: 2
> + maxItems: 3
> items:
> - description:
> Register block of mhdptx apb registers up to PHY mapped area (AUX_CONFIG_P).
> @@ -26,13 +26,16 @@ properties:
> included in the associated PHY.
> - description:
> Register block for DSS_EDP0_INTG_CFG_VP registers in case of TI J7 SoCs.
> + - description:
> + Register block of mhdptx sapb registers.
>
> reg-names:
> - minItems: 1
> - maxItems: 2
> + minItems: 2
> + maxItems: 3
> items:
> - const: mhdptx
> - const: j721e-intg
> + - const: mhdptx-sapb
>
> clocks:
> maxItems: 1
> @@ -98,15 +101,15 @@ allOf:
> then:
> properties:
> reg:
> - minItems: 2
> + minItems: 3
> reg-names:
> - minItems: 2
> + minItems: 3
> else:
> properties:
> reg:
> - maxItems: 1
> + maxItems: 2
> reg-names:
> - maxItems: 1
> + maxItems: 2
>
> required:
> - compatible
> @@ -129,8 +132,9 @@ examples:
>
> mhdp: dp-bridge@f0fb000000 {
> compatible = "cdns,mhdp8546";
> - reg = <0xf0 0xfb000000 0x0 0x1000000>;
> - reg-names = "mhdptx";
> + reg = <0xf0 0xfb000000 0x0 0x1000000>,
> + <0x0 0x4f48000 0x0 0x74>;
> + reg-names = "mhdptx", "mhdptx-sapb";

Running

make dt_binding_check DT_SCHEMA_FILES=Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml

produces

LINT Documentation/devicetree/bindings
CHKDT Documentation/devicetree/bindings/processed-schema-examples.json
SCHEMA Documentation/devicetree/bindings/processed-schema-examples.json
DTEX Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.example.dts
DTC Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.example.dt.yaml
CHECK Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.example.dt.yaml
Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.example.dt.yaml: dp-bridge@f0fb000000: reg-names:1: 'j721e-intg' was expected
From schema: Documentation/devicetree/bindings/display/bridge/cdns,mhdp8546.yaml

This is caused by the fact that reg-names is correctly limited to two
elements, but then expects the second element to be "j721e-intg". The
example is good, so it's the bindings that need to be fixed.

> clocks = <&mhdp_clock>;
> phys = <&dp_phy>;
> phy-names = "dpphy";

--
Regards,

Laurent Pinchart