From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932381AbeD0IjA convert rfc822-to-8bit (ORCPT ); Fri, 27 Apr 2018 04:39:00 -0400 Received: from hermes.aosc.io ([199.195.250.187]:44618 "EHLO hermes.aosc.io" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932354AbeD0Ii7 (ORCPT ); Fri, 27 Apr 2018 04:38:59 -0400 Date: Fri, 27 Apr 2018 16:38:29 +0800 In-Reply-To: References: <20180426140728.43155-1-icenowy@aosc.io> <20180426140728.43155-2-icenowy@aosc.io> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8BIT Subject: Re: [linux-sunxi] [PATCH 1/3] mmc: sunxi: add support for the MMC controller on H6 To: linux-arm-kernel@lists.infradead.org, Andre Przywara , Ulf Hansson , Rob Herring , Maxime Ripard , Chen-Yu Tsai CC: devicetree@vger.kernel.org, linux-sunxi@googlegroups.com, linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org From: Icenowy Zheng Message-ID: Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 于 2018年4月27日 GMT+08:00 上午12:45:24, Andre Przywara 写到: >Hi, > >On 26/04/18 15:07, Icenowy Zheng wrote: >> The new Allwinner H6 SoC have 3 MMC controllers. The first and second >> ones are similar to the ones on A64, but the third one adds EMCE >> (Embedded Crypto Engine) support which does hardware transparent >crypto >> on the eMMC. >> >> As we still do not have support for EMCE, and the support of it is >> disabled by defualt, we just duplicate the A64 mmc configurations and >> change the compatible string. > >So if the A64 MMC part is compatible, we should express it like this: > >> Signed-off-by: Icenowy Zheng >> --- >> Documentation/devicetree/bindings/mmc/sunxi-mmc.txt | 2 ++ >> drivers/mmc/host/sunxi-mmc.c | 16 >++++++++++++++++ >> 2 files changed, 18 insertions(+) >> >> diff --git a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> index 132e0007d7d6..e6aa5c7a5e12 100644 >> --- a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> +++ b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> @@ -16,6 +16,8 @@ Required properties: >> * "allwinner,sun9i-a80-mmc" >> * "allwinner,sun50i-a64-emmc" >> * "allwinner,sun50i-a64-mmc" >> + * "allwinner,sun50i-h6-emmc" >> + * "allwinner,sun50i-h6-mmc" > >This should be changed to: > > * "allwinner,sun50i-h6-emmc", "allwinner,sun50i-a64-emmc" > * "allwinner,sun50i-h6-mmc", "allwinner,sun50i-a64-mmc" This list shouldn't list pairs, and as I said in the reply, these pairs are not valid. > >> - reg : mmc controller base registers >> - clocks : a list with 4 phandle + clock specifier pairs >> - clock-names : must contain "ahb", "mmc", "output" and "sample" >> diff --git a/drivers/mmc/host/sunxi-mmc.c >b/drivers/mmc/host/sunxi-mmc.c >> index 97c6b79b7d6f..05e2b5fd7aa4 100644 >> --- a/drivers/mmc/host/sunxi-mmc.c >> +++ b/drivers/mmc/host/sunxi-mmc.c >> @@ -1168,6 +1168,20 @@ static const struct sunxi_mmc_cfg >sun50i_a64_emmc_cfg = { >> .can_calibrate = true, >> }; >> >> +static const struct sunxi_mmc_cfg sun50i_h6_cfg = { >> + .idma_des_size_bits = 16, >> + .clk_delays = NULL, >> + .can_calibrate = true, >> + .mask_data0 = true, >> + .needs_new_timings = true, >> +}; >> + >> +static const struct sunxi_mmc_cfg sun50i_h6_emmc_cfg = { >> + .idma_des_size_bits = 13, >> + .clk_delays = NULL, >> + .can_calibrate = true, >> +}; >> + > >... and then we don't need those changes ... > >> static const struct of_device_id sunxi_mmc_of_match[] = { >> { .compatible = "allwinner,sun4i-a10-mmc", .data = &sun4i_a10_cfg >}, >> { .compatible = "allwinner,sun5i-a13-mmc", .data = &sun5i_a13_cfg >}, >> @@ -1176,6 +1190,8 @@ static const struct of_device_id >sunxi_mmc_of_match[] = { >> { .compatible = "allwinner,sun9i-a80-mmc", .data = &sun9i_a80_cfg >}, >> { .compatible = "allwinner,sun50i-a64-mmc", .data = &sun50i_a64_cfg >}, >> { .compatible = "allwinner,sun50i-a64-emmc", .data = >&sun50i_a64_emmc_cfg }, >> + { .compatible = "allwinner,sun50i-h6-mmc", .data = &sun50i_h6_cfg >}, >> + { .compatible = "allwinner,sun50i-h6-emmc", .data = >&sun50i_h6_emmc_cfg }, > >... and those, at least yet. >Should we ever extend the driver to support the EMCE, we can add them >at >this occasion. > >So this patch would just add the compatible pairs to the binding doc. > >Cheers, >Andre. > >> { /* sentinel */ } >> }; >> MODULE_DEVICE_TABLE(of, sunxi_mmc_of_match); >> > >_______________________________________________ >linux-arm-kernel mailing list >linux-arm-kernel@lists.infradead.org >http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 From: Icenowy Zheng Subject: Re: [PATCH 1/3] mmc: sunxi: add support for the MMC controller on H6 Date: Fri, 27 Apr 2018 16:38:29 +0800 Message-ID: References: <20180426140728.43155-1-icenowy@aosc.io> <20180426140728.43155-2-icenowy@aosc.io> Reply-To: icenowy-h8G6r0blFSE@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Return-path: Sender: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org In-Reply-To: List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , To: linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, Andre Przywara , Ulf Hansson , Rob Herring , Maxime Ripard , Chen-Yu Tsai Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org, linux-mmc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org List-Id: devicetree@vger.kernel.org =E4=BA=8E 2018=E5=B9=B44=E6=9C=8827=E6=97=A5 GMT+08:00 =E4=B8=8A=E5=8D=8812= :45:24, Andre Przywara =E5=86=99=E5=88=B0: >Hi, > >On 26/04/18 15:07, Icenowy Zheng wrote: >> The new Allwinner H6 SoC have 3 MMC controllers. The first and second >> ones are similar to the ones on A64, but the third one adds EMCE >> (Embedded Crypto Engine) support which does hardware transparent >crypto >> on the eMMC. >>=20 >> As we still do not have support for EMCE, and the support of it is >> disabled by defualt, we just duplicate the A64 mmc configurations and >> change the compatible string. > >So if the A64 MMC part is compatible, we should express it like this: > >> Signed-off-by: Icenowy Zheng >> --- >> Documentation/devicetree/bindings/mmc/sunxi-mmc.txt | 2 ++ >> drivers/mmc/host/sunxi-mmc.c | 16 >++++++++++++++++ >> 2 files changed, 18 insertions(+) >>=20 >> diff --git a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> index 132e0007d7d6..e6aa5c7a5e12 100644 >> --- a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> +++ b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> @@ -16,6 +16,8 @@ Required properties: >> * "allwinner,sun9i-a80-mmc" >> * "allwinner,sun50i-a64-emmc" >> * "allwinner,sun50i-a64-mmc" >> + * "allwinner,sun50i-h6-emmc" >> + * "allwinner,sun50i-h6-mmc" > >This should be changed to: > > * "allwinner,sun50i-h6-emmc", "allwinner,sun50i-a64-emmc" > * "allwinner,sun50i-h6-mmc", "allwinner,sun50i-a64-mmc" This list shouldn't list pairs, and as I said in the reply, these pairs are not valid. > >> - reg : mmc controller base registers >> - clocks : a list with 4 phandle + clock specifier pairs >> - clock-names : must contain "ahb", "mmc", "output" and "sample" >> diff --git a/drivers/mmc/host/sunxi-mmc.c >b/drivers/mmc/host/sunxi-mmc.c >> index 97c6b79b7d6f..05e2b5fd7aa4 100644 >> --- a/drivers/mmc/host/sunxi-mmc.c >> +++ b/drivers/mmc/host/sunxi-mmc.c >> @@ -1168,6 +1168,20 @@ static const struct sunxi_mmc_cfg >sun50i_a64_emmc_cfg =3D { >> .can_calibrate =3D true, >> }; >> =20 >> +static const struct sunxi_mmc_cfg sun50i_h6_cfg =3D { >> + .idma_des_size_bits =3D 16, >> + .clk_delays =3D NULL, >> + .can_calibrate =3D true, >> + .mask_data0 =3D true, >> + .needs_new_timings =3D true, >> +}; >> + >> +static const struct sunxi_mmc_cfg sun50i_h6_emmc_cfg =3D { >> + .idma_des_size_bits =3D 13, >> + .clk_delays =3D NULL, >> + .can_calibrate =3D true, >> +}; >> + > >... and then we don't need those changes ... > >> static const struct of_device_id sunxi_mmc_of_match[] =3D { >> { .compatible =3D "allwinner,sun4i-a10-mmc", .data =3D &sun4i_a10_cfg >}, >> { .compatible =3D "allwinner,sun5i-a13-mmc", .data =3D &sun5i_a13_cfg >}, >> @@ -1176,6 +1190,8 @@ static const struct of_device_id >sunxi_mmc_of_match[] =3D { >> { .compatible =3D "allwinner,sun9i-a80-mmc", .data =3D &sun9i_a80_cfg >}, >> { .compatible =3D "allwinner,sun50i-a64-mmc", .data =3D &sun50i_a64_cf= g >}, >> { .compatible =3D "allwinner,sun50i-a64-emmc", .data =3D >&sun50i_a64_emmc_cfg }, >> + { .compatible =3D "allwinner,sun50i-h6-mmc", .data =3D &sun50i_h6_cfg >}, >> + { .compatible =3D "allwinner,sun50i-h6-emmc", .data =3D >&sun50i_h6_emmc_cfg }, > >... and those, at least yet. >Should we ever extend the driver to support the EMCE, we can add them >at >this occasion. > >So this patch would just add the compatible pairs to the binding doc. > >Cheers, >Andre. > >> { /* sentinel */ } >> }; >> MODULE_DEVICE_TABLE(of, sunxi_mmc_of_match); >>=20 > >_______________________________________________ >linux-arm-kernel mailing list >linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org >http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --=20 You received this message because you are subscribed to the Google Groups "= linux-sunxi" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit https://groups.google.com/d/optout. From mboxrd@z Thu Jan 1 00:00:00 1970 From: icenowy@aosc.io (Icenowy Zheng) Date: Fri, 27 Apr 2018 16:38:29 +0800 Subject: [linux-sunxi] [PATCH 1/3] mmc: sunxi: add support for the MMC controller on H6 In-Reply-To: References: <20180426140728.43155-1-icenowy@aosc.io> <20180426140728.43155-2-icenowy@aosc.io> Message-ID: To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org ? 2018?4?27? GMT+08:00 ??12:45:24, Andre Przywara ??: >Hi, > >On 26/04/18 15:07, Icenowy Zheng wrote: >> The new Allwinner H6 SoC have 3 MMC controllers. The first and second >> ones are similar to the ones on A64, but the third one adds EMCE >> (Embedded Crypto Engine) support which does hardware transparent >crypto >> on the eMMC. >> >> As we still do not have support for EMCE, and the support of it is >> disabled by defualt, we just duplicate the A64 mmc configurations and >> change the compatible string. > >So if the A64 MMC part is compatible, we should express it like this: > >> Signed-off-by: Icenowy Zheng >> --- >> Documentation/devicetree/bindings/mmc/sunxi-mmc.txt | 2 ++ >> drivers/mmc/host/sunxi-mmc.c | 16 >++++++++++++++++ >> 2 files changed, 18 insertions(+) >> >> diff --git a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> index 132e0007d7d6..e6aa5c7a5e12 100644 >> --- a/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> +++ b/Documentation/devicetree/bindings/mmc/sunxi-mmc.txt >> @@ -16,6 +16,8 @@ Required properties: >> * "allwinner,sun9i-a80-mmc" >> * "allwinner,sun50i-a64-emmc" >> * "allwinner,sun50i-a64-mmc" >> + * "allwinner,sun50i-h6-emmc" >> + * "allwinner,sun50i-h6-mmc" > >This should be changed to: > > * "allwinner,sun50i-h6-emmc", "allwinner,sun50i-a64-emmc" > * "allwinner,sun50i-h6-mmc", "allwinner,sun50i-a64-mmc" This list shouldn't list pairs, and as I said in the reply, these pairs are not valid. > >> - reg : mmc controller base registers >> - clocks : a list with 4 phandle + clock specifier pairs >> - clock-names : must contain "ahb", "mmc", "output" and "sample" >> diff --git a/drivers/mmc/host/sunxi-mmc.c >b/drivers/mmc/host/sunxi-mmc.c >> index 97c6b79b7d6f..05e2b5fd7aa4 100644 >> --- a/drivers/mmc/host/sunxi-mmc.c >> +++ b/drivers/mmc/host/sunxi-mmc.c >> @@ -1168,6 +1168,20 @@ static const struct sunxi_mmc_cfg >sun50i_a64_emmc_cfg = { >> .can_calibrate = true, >> }; >> >> +static const struct sunxi_mmc_cfg sun50i_h6_cfg = { >> + .idma_des_size_bits = 16, >> + .clk_delays = NULL, >> + .can_calibrate = true, >> + .mask_data0 = true, >> + .needs_new_timings = true, >> +}; >> + >> +static const struct sunxi_mmc_cfg sun50i_h6_emmc_cfg = { >> + .idma_des_size_bits = 13, >> + .clk_delays = NULL, >> + .can_calibrate = true, >> +}; >> + > >... and then we don't need those changes ... > >> static const struct of_device_id sunxi_mmc_of_match[] = { >> { .compatible = "allwinner,sun4i-a10-mmc", .data = &sun4i_a10_cfg >}, >> { .compatible = "allwinner,sun5i-a13-mmc", .data = &sun5i_a13_cfg >}, >> @@ -1176,6 +1190,8 @@ static const struct of_device_id >sunxi_mmc_of_match[] = { >> { .compatible = "allwinner,sun9i-a80-mmc", .data = &sun9i_a80_cfg >}, >> { .compatible = "allwinner,sun50i-a64-mmc", .data = &sun50i_a64_cfg >}, >> { .compatible = "allwinner,sun50i-a64-emmc", .data = >&sun50i_a64_emmc_cfg }, >> + { .compatible = "allwinner,sun50i-h6-mmc", .data = &sun50i_h6_cfg >}, >> + { .compatible = "allwinner,sun50i-h6-emmc", .data = >&sun50i_h6_emmc_cfg }, > >... and those, at least yet. >Should we ever extend the driver to support the EMCE, we can add them >at >this occasion. > >So this patch would just add the compatible pairs to the binding doc. > >Cheers, >Andre. > >> { /* sentinel */ } >> }; >> MODULE_DEVICE_TABLE(of, sunxi_mmc_of_match); >> > >_______________________________________________ >linux-arm-kernel mailing list >linux-arm-kernel at lists.infradead.org >http://lists.infradead.org/mailman/listinfo/linux-arm-kernel