mbox series

[v2,0/3] Add support for sc7280 WPSS PIL loading

Message ID 1628618483-664-1-git-send-email-pillair@codeaurora.org
Headers show
Series Add support for sc7280 WPSS PIL loading | expand

Message

Rakesh Pillai Aug. 10, 2021, 6:01 p.m. UTC
Add support for PIL loading of WPSS co-processor for SC7280 SOCs.

Rakesh Pillai (3):
  dt-bindings: remoteproc: qcom: adsp: Convert binding to YAML
  dt-bindings: remoteproc: qcom: Add SC7280 WPSS support
  remoteproc: qcom: q6v5_wpss: Add support for sc7280 WPSS

 .../bindings/remoteproc/qcom,hexagon-v56.txt       | 140 --------
 .../bindings/remoteproc/qcom,hexagon-v56.yaml      | 361 +++++++++++++++++++++
 drivers/remoteproc/qcom_q6v5_adsp.c                |  70 +++-
 3 files changed, 430 insertions(+), 141 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.txt
 create mode 100644 Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml

Comments

Rob Herring (Arm) Aug. 11, 2021, 5:24 p.m. UTC | #1
On Tue, 10 Aug 2021 23:31:22 +0530, Rakesh Pillai wrote:
> Add WPSS PIL loading support for SC7280 SoCs.
> 
> Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
> ---
>  .../bindings/remoteproc/qcom,hexagon-v56.yaml      | 79 ++++++++++++++++++++--
>  1 file changed, 74 insertions(+), 5 deletions(-)
> 

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check'
on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.example.dt.yaml: remoteproc@17300000: 'power-domain-names' is a required property
	From schema: /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/1515482

This check can fail if there are any dependencies. The base for a patch
series is generally the most recent rc1.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit.
Rob Herring (Arm) Aug. 11, 2021, 5:37 p.m. UTC | #2
On Tue, Aug 10, 2021 at 11:31:22PM +0530, Rakesh Pillai wrote:
> Add WPSS PIL loading support for SC7280 SoCs.

> 

> Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>

> ---

>  .../bindings/remoteproc/qcom,hexagon-v56.yaml      | 79 ++++++++++++++++++++--

>  1 file changed, 74 insertions(+), 5 deletions(-)

> 

> diff --git a/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml b/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml

> index 5f3558e..9ae433c6 100644

> --- a/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml

> +++ b/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-v56.yaml

> @@ -17,6 +17,7 @@ properties:

>    compatible:

>      enum:

>        - qcom,qcs404-cdsp-pil

> +      - qcom,sc7280-wpss-pil

>        - qcom,sdm845-adsp-pil

>  

>    reg:

> @@ -26,25 +27,30 @@ properties:

>  

>    interrupts-extended:

>      minItems: 5

> -    maxItems: 5

> +    maxItems: 6

>  

>    interrupt-names:

>      minItems: 5

> -    maxItems: 5

> +    maxItems: 6

>  

>    clocks:

> -    minItems: 7

> +    minItems: 3


Patch 1 shows 3 clocks are valid...

>      maxItems: 8

>      description:

>        List of phandles and clock specifier pairs for the Hexagon,

>        per clock-names below.

>  

>    clock-names:

> -    minItems: 7

> +    minItems: 3

>      maxItems: 8

>  

>    power-domains:

> -    maxItems: 1

> +    minItems: 1

> +    maxItems: 2

> +

> +  power-domain-names:

> +    minItems: 1

> +    maxItems: 2

>  

>    resets:

>      minItems: 1

> @@ -92,6 +98,7 @@ required:

>    - clocks

>    - clock-names

>    - power-domains

> +  - power-domain-names


It's not backwards compatible to add a required property.

>    - qcom,halt-regs

>    - memory-region

>    - qcom,smem-states

> @@ -129,6 +136,31 @@ allOf:

>          compatible:

>            contains:

>              enum:

> +              - qcom,sc7280-wpss-pil

> +    then:

> +      properties:

> +        interrupts-extended:

> +          items:

> +            - description: Watchdog interrupt

> +            - description: Fatal interrupt

> +            - description: Ready interrupt

> +            - description: Handover interrupt

> +            - description: Stop acknowledge interrupt

> +            - description: Shutdown acknowledge interrupt

> +        interrupt-names:

> +          items:

> +            - const: wdog

> +            - const: fatal

> +            - const: ready

> +            - const: handover

> +            - const: stop-ack

> +            - const: shutdown-ack


The items lists can go in the main section with 'minItems: 5' and just 
'minItems: 6' here.

> +

> +  - if:

> +      properties:

> +        compatible:

> +          contains:

> +            enum:

>                - qcom,sdm845-adsp-pil

>      then:

>        properties:

> @@ -211,6 +243,26 @@ allOf:

>          power-domains:

>            items:

>              - description: CX power domain

> +        power-domain-names:

> +          items:

> +            - const: cx

> +

> +  - if:

> +      properties:

> +        compatible:

> +          contains:

> +            enum:

> +              - qcom,sc7280-wpss-pil

> +    then:

> +      properties:

> +        power-domains:

> +          items:

> +            - description: CX power domain

> +            - description: MX power domain

> +        power-domain-names:

> +          items:

> +            - const: cx

> +            - const: mx


As 'cx' is always the first entry, the 'items' lists here can be moved 
to the main section and you just need minItems or maxItems in the 
if/then.

>  

>    - if:

>        properties:

> @@ -244,6 +296,23 @@ allOf:

>            items:

>              - const: restart

>  

> +  - if:

> +      properties:

> +        compatible:

> +          contains:

> +            enum:

> +              - qcom,sc7280-wpss-pil

> +    then:

> +      properties:

> +        resets:

> +          items:

> +            - description: AOSS restart

> +            - description: PDC SYNC

> +        reset-names:

> +          items:

> +            - const: restart

> +            - const: pdc_sync

> +

>  examples:

>    - |

>      #include <dt-bindings/interrupt-controller/arm-gic.h>

> -- 

> 2.7.4

> 

>
Rakesh Pillai Sept. 9, 2021, 8:36 a.m. UTC | #3
> -----Original Message-----
> From: Rob Herring <robh@kernel.org>
> Sent: Wednesday, August 11, 2021 10:55 PM
> To: Rakesh Pillai <pillair@codeaurora.org>
> Cc: robh+dt@kernel.org; sibis@codeaurora.org; sboyd@kernel.org;
> bjorn.andersson@linaro.org; agross@kernel.org; linux-
> kernel@vger.kernel.org; devicetree@vger.kernel.org;
> mpubbise@codeaurora.org; linux-arm-msm@vger.kernel.org
> Subject: Re: [PATCH v2 2/3] dt-bindings: remoteproc: qcom: Add SC7280
> WPSS support
> 
> On Tue, 10 Aug 2021 23:31:22 +0530, Rakesh Pillai wrote:
> > Add WPSS PIL loading support for SC7280 SoCs.
> >
> > Signed-off-by: Rakesh Pillai <pillair@codeaurora.org>
> > ---
> >  .../bindings/remoteproc/qcom,hexagon-v56.yaml      | 79
> ++++++++++++++++++++--
> >  1 file changed, 74 insertions(+), 5 deletions(-)
> >
> 
> My bot found errors running 'make DT_CHECKER_FLAGS=-m
> dt_binding_check'
> on your patch (DT_CHECKER_FLAGS is new in v5.13):
> 
> yamllint warnings/errors:
> 
> dtschema/dtc warnings/errors:
> /builds/robherring/linux-dt-
> review/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-
> v56.example.dt.yaml: remoteproc@17300000: 'power-domain-names' is a
> required property
> 	From schema: /builds/robherring/linux-dt-
> review/Documentation/devicetree/bindings/remoteproc/qcom,hexagon-
> v56.yaml
> 
> doc reference errors (make refcheckdocs):
> 
> See https://patchwork.ozlabs.org/patch/1515482
> 
> This check can fail if there are any dependencies. The base for a patch
series
> is generally the most recent rc1.
> 
> If you already ran 'make dt_binding_check' and didn't see the above
error(s),
> then make sure 'yamllint' is installed and dt-schema is up to
> date:
> 
> pip3 install dtschema --upgrade
> 
> Please check and re-submit.

Thanks Rob, I will submit next patchset for this and fix the issues.