public inbox for devicetree@vger.kernel.org
 help / color / mirror / Atom feed
From: Conor Dooley <conor@kernel.org>
To: Jiayu Du <jiayu.riscv@isrc.iscas.ac.cn>
Cc: ulf.hansson@linaro.org, adrian.hunter@intel.com, robh@kernel.org,
	krzk+dt@kernel.org, conor+dt@kernel.org, pjw@kernel.org,
	palmer@dabbelt.com, aou@eecs.berkeley.edu,
	linux-mmc@vger.kernel.org, devicetree@vger.kernel.org,
	linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org,
	gaohan@iscas.ac.cn, me@ziyao.cc
Subject: Re: [PATCH 1/3] dt-bindings: mmc: Add sdhci support for Canaan k230
Date: Wed, 4 Feb 2026 18:10:25 +0000	[thread overview]
Message-ID: <20260204-imperfect-blitz-55fe5a85590f@spud> (raw)
In-Reply-To: <20260204082908.27501-2-jiayu.riscv@isrc.iscas.ac.cn>

[-- Attachment #1: Type: text/plain, Size: 2074 bytes --]

On Wed, Feb 04, 2026 at 04:29:06PM +0800, Jiayu Du wrote:
> The Canaan k230 uses the SDHCI from Synopsys. Add compatible strings
> to the k230. The k230 has two controllers. MMC0 supports eMMC, while
> MMC1 supports SDIO.
> 
> Signed-off-by: Jiayu Du <jiayu.riscv@isrc.iscas.ac.cn>
> ---
>  .../bindings/mmc/snps,dwcmshc-sdhci.yaml      | 22 +++++++++++++++++++
>  1 file changed, 22 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/mmc/snps,dwcmshc-sdhci.yaml b/Documentation/devicetree/bindings/mmc/snps,dwcmshc-sdhci.yaml
> index 7e7c55dc2440..cab33da3af7d 100644
> --- a/Documentation/devicetree/bindings/mmc/snps,dwcmshc-sdhci.yaml
> +++ b/Documentation/devicetree/bindings/mmc/snps,dwcmshc-sdhci.yaml
> @@ -23,6 +23,8 @@ properties:
>            - const: sophgo,sg2044-dwcmshc
>            - const: sophgo,sg2042-dwcmshc
>        - enum:
> +          - canaan,k230-emmc
> +          - canaan,k230-sdio

I don't understand why there are two compatibles here, when the driver
is able to handle them both identically, using the common properties for
mmc controllers to differentiate. Is which is emmc and which sdio
actually just determined by how the k230 boards use them?

Or, if there are pinout differences, would pinctrl allow each to be used
for either?

>            - rockchip,rk3568-dwcmshc
>            - rockchip,rk3588-dwcmshc
>            - snps,dwcmshc-sdhci
> @@ -87,6 +89,26 @@ required:
>  allOf:
>    - $ref: mmc-controller.yaml#
>  
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - canaan,k230-emmc
> +              - canaan,k230-sdio
> +    then:
> +      properties:
> +        clocks:
> +          minItems: 2
> +          maxItems: 5
> +        clock-names:
> +          items:
> +            - const: core
> +            - const: bus
> +            - const: axi
> +            - const: block
> +            - const: timer
> +
>    - if:
>        properties:
>          compatible:
> -- 
> 2.52.0
> 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 228 bytes --]

  reply	other threads:[~2026-02-04 18:10 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-04  8:29 [PATCH 0/3] Add SDHCI support for Canaan K230 SoC Jiayu Du
2026-02-04  8:29 ` [PATCH 1/3] dt-bindings: mmc: Add sdhci support for Canaan k230 Jiayu Du
2026-02-04 18:10   ` Conor Dooley [this message]
2026-02-05  7:13     ` Jiayu Du
2026-02-05 19:19       ` Conor Dooley
2026-02-06  2:56         ` Jiayu Du
2026-02-04  8:29 ` [PATCH 2/3] mmc: sdhci-dwcmshc: Add Canaan K230 DWCMSHC controller support Jiayu Du
2026-02-04  9:43   ` Yao Zi
2026-02-06 13:26   ` Krzysztof Kozlowski
2026-02-07  8:45     ` Jiayu Du
2026-02-07  9:32       ` Krzysztof Kozlowski
2026-02-08 15:44         ` Jiayu Du
2026-02-04  8:29 ` [PATCH 3/3] riscv: dts: canaan: Add mmc nodes for K230 Jiayu Du

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=20260204-imperfect-blitz-55fe5a85590f@spud \
    --to=conor@kernel.org \
    --cc=adrian.hunter@intel.com \
    --cc=aou@eecs.berkeley.edu \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=gaohan@iscas.ac.cn \
    --cc=jiayu.riscv@isrc.iscas.ac.cn \
    --cc=krzk+dt@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=me@ziyao.cc \
    --cc=palmer@dabbelt.com \
    --cc=pjw@kernel.org \
    --cc=robh@kernel.org \
    --cc=ulf.hansson@linaro.org \
    /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