From mboxrd@z Thu Jan 1 00:00:00 1970 From: Geert Uytterhoeven Subject: Re: [PATCH 2/3] clk: renesas: r8a7795: Add ccree clock Date: Thu, 17 May 2018 10:41:46 +0200 Message-ID: References: <1526387370-17142-1-git-send-email-gilad@benyossef.com> <1526387370-17142-3-git-send-email-gilad@benyossef.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Cc: Simon Horman , Magnus Damm , Rob Herring , Mark Rutland , Catalin Marinas , Will Deacon , Geert Uytterhoeven , Michael Turquette , Stephen Boyd , Herbert Xu , "David S. Miller" , Ofir Drang , Linux-Renesas , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux ARM , Linux Kernel Mailing List , linux-clk , L To: Gilad Ben-Yossef Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-crypto.vger.kernel.org Hi Gilad, On Thu, May 17, 2018 at 10:00 AM, Gilad Ben-Yossef wrote: > On Tue, May 15, 2018 at 5:47 PM, Geert Uytterhoeven > wrote: >> On Tue, May 15, 2018 at 2:29 PM, Gilad Ben-Yossef wrote: >>> This patch adds the clock used by the CryptoCell 630p instance in the SoC. >>> >>> Signed-off-by: Gilad Ben-Yossef >> >> Thanks for your patch! >> >>> --- a/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> +++ b/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> @@ -132,6 +132,7 @@ static struct mssr_mod_clk r8a7795_mod_clks[] __initdata = { >>> DEF_MOD("sys-dmac2", 217, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac1", 218, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac0", 219, R8A7795_CLK_S0D3), >>> + DEF_MOD("ccree", 229, R8A7795_CLK_S3D2), >> >> I don't know if "ccree" is the proper name for this clock, as there >> may be multiple >> instances. > > I'd be happy to rename it to anything else. Suggestions? I believe it should be called "sceg-pub". >> I also can't verify the parent clock. > > I'm afraid I can't really help. This is based on code snippet from > Renesas. I verified it works but > I am not an expert on the clock settings :-( As your driver doesn't care about the clock rate, only about enabling/disabling the clock, the actual parent doesn't matter much. After some deeper diving into the datasheet, I believe the correct parent is the CR clock, which is unfortunately not yet supported by the R-Car H3 clock driver. I'll send a patch... Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751438AbeEQIlx (ORCPT ); Thu, 17 May 2018 04:41:53 -0400 Received: from mail-ua0-f194.google.com ([209.85.217.194]:44161 "EHLO mail-ua0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751409AbeEQIlr (ORCPT ); Thu, 17 May 2018 04:41:47 -0400 X-Google-Smtp-Source: AB8JxZp1wvgLrFSNsAWrQqbRVxgszHp3Wi5/hFwc8FmFpJvH1Vj4lp/dDufdkHU9ihMxLXT376nGJs8QR0Ji9DczhcM= MIME-Version: 1.0 In-Reply-To: References: <1526387370-17142-1-git-send-email-gilad@benyossef.com> <1526387370-17142-3-git-send-email-gilad@benyossef.com> From: Geert Uytterhoeven Date: Thu, 17 May 2018 10:41:46 +0200 X-Google-Sender-Auth: o-kHCnH5JNcjMivl6phkjrxs-2c Message-ID: Subject: Re: [PATCH 2/3] clk: renesas: r8a7795: Add ccree clock To: Gilad Ben-Yossef Cc: Simon Horman , Magnus Damm , Rob Herring , Mark Rutland , Catalin Marinas , Will Deacon , Geert Uytterhoeven , Michael Turquette , Stephen Boyd , Herbert Xu , "David S. Miller" , Ofir Drang , Linux-Renesas , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux ARM , Linux Kernel Mailing List , linux-clk , Linux Crypto Mailing List Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Gilad, On Thu, May 17, 2018 at 10:00 AM, Gilad Ben-Yossef wrote: > On Tue, May 15, 2018 at 5:47 PM, Geert Uytterhoeven > wrote: >> On Tue, May 15, 2018 at 2:29 PM, Gilad Ben-Yossef wrote: >>> This patch adds the clock used by the CryptoCell 630p instance in the SoC. >>> >>> Signed-off-by: Gilad Ben-Yossef >> >> Thanks for your patch! >> >>> --- a/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> +++ b/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> @@ -132,6 +132,7 @@ static struct mssr_mod_clk r8a7795_mod_clks[] __initdata = { >>> DEF_MOD("sys-dmac2", 217, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac1", 218, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac0", 219, R8A7795_CLK_S0D3), >>> + DEF_MOD("ccree", 229, R8A7795_CLK_S3D2), >> >> I don't know if "ccree" is the proper name for this clock, as there >> may be multiple >> instances. > > I'd be happy to rename it to anything else. Suggestions? I believe it should be called "sceg-pub". >> I also can't verify the parent clock. > > I'm afraid I can't really help. This is based on code snippet from > Renesas. I verified it works but > I am not an expert on the clock settings :-( As your driver doesn't care about the clock rate, only about enabling/disabling the clock, the actual parent doesn't matter much. After some deeper diving into the datasheet, I believe the correct parent is the CR clock, which is unfortunately not yet supported by the R-Car H3 clock driver. I'll send a patch... Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds From mboxrd@z Thu Jan 1 00:00:00 1970 From: Geert Uytterhoeven Subject: Re: [PATCH 2/3] clk: renesas: r8a7795: Add ccree clock Date: Thu, 17 May 2018 10:41:46 +0200 Message-ID: References: <1526387370-17142-1-git-send-email-gilad@benyossef.com> <1526387370-17142-3-git-send-email-gilad@benyossef.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Gilad Ben-Yossef Cc: Simon Horman , Magnus Damm , Rob Herring , Mark Rutland , Catalin Marinas , Will Deacon , Geert Uytterhoeven , Michael Turquette , Stephen Boyd , Herbert Xu , "David S. Miller" , Ofir Drang , Linux-Renesas , "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" , Linux ARM , Linux Kernel Mailing List , linux-clk L List-Id: devicetree@vger.kernel.org Hi Gilad, On Thu, May 17, 2018 at 10:00 AM, Gilad Ben-Yossef wrote: > On Tue, May 15, 2018 at 5:47 PM, Geert Uytterhoeven > wrote: >> On Tue, May 15, 2018 at 2:29 PM, Gilad Ben-Yossef wrote: >>> This patch adds the clock used by the CryptoCell 630p instance in the SoC. >>> >>> Signed-off-by: Gilad Ben-Yossef >> >> Thanks for your patch! >> >>> --- a/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> +++ b/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> @@ -132,6 +132,7 @@ static struct mssr_mod_clk r8a7795_mod_clks[] __initdata = { >>> DEF_MOD("sys-dmac2", 217, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac1", 218, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac0", 219, R8A7795_CLK_S0D3), >>> + DEF_MOD("ccree", 229, R8A7795_CLK_S3D2), >> >> I don't know if "ccree" is the proper name for this clock, as there >> may be multiple >> instances. > > I'd be happy to rename it to anything else. Suggestions? I believe it should be called "sceg-pub". >> I also can't verify the parent clock. > > I'm afraid I can't really help. This is based on code snippet from > Renesas. I verified it works but > I am not an expert on the clock settings :-( As your driver doesn't care about the clock rate, only about enabling/disabling the clock, the actual parent doesn't matter much. After some deeper diving into the datasheet, I believe the correct parent is the CR clock, which is unfortunately not yet supported by the R-Car H3 clock driver. I'll send a patch... Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds From mboxrd@z Thu Jan 1 00:00:00 1970 From: geert@linux-m68k.org (Geert Uytterhoeven) Date: Thu, 17 May 2018 10:41:46 +0200 Subject: [PATCH 2/3] clk: renesas: r8a7795: Add ccree clock In-Reply-To: References: <1526387370-17142-1-git-send-email-gilad@benyossef.com> <1526387370-17142-3-git-send-email-gilad@benyossef.com> Message-ID: To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org Hi Gilad, On Thu, May 17, 2018 at 10:00 AM, Gilad Ben-Yossef wrote: > On Tue, May 15, 2018 at 5:47 PM, Geert Uytterhoeven > wrote: >> On Tue, May 15, 2018 at 2:29 PM, Gilad Ben-Yossef wrote: >>> This patch adds the clock used by the CryptoCell 630p instance in the SoC. >>> >>> Signed-off-by: Gilad Ben-Yossef >> >> Thanks for your patch! >> >>> --- a/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> +++ b/drivers/clk/renesas/r8a7795-cpg-mssr.c >>> @@ -132,6 +132,7 @@ static struct mssr_mod_clk r8a7795_mod_clks[] __initdata = { >>> DEF_MOD("sys-dmac2", 217, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac1", 218, R8A7795_CLK_S0D3), >>> DEF_MOD("sys-dmac0", 219, R8A7795_CLK_S0D3), >>> + DEF_MOD("ccree", 229, R8A7795_CLK_S3D2), >> >> I don't know if "ccree" is the proper name for this clock, as there >> may be multiple >> instances. > > I'd be happy to rename it to anything else. Suggestions? I believe it should be called "sceg-pub". >> I also can't verify the parent clock. > > I'm afraid I can't really help. This is based on code snippet from > Renesas. I verified it works but > I am not an expert on the clock settings :-( As your driver doesn't care about the clock rate, only about enabling/disabling the clock, the actual parent doesn't matter much. After some deeper diving into the datasheet, I believe the correct parent is the CR clock, which is unfortunately not yet supported by the R-Car H3 clock driver. I'll send a patch... Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that. -- Linus Torvalds