lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAAfSe-uu4gW5sGfQruCGWzJeANYnqq6Kc5kQZJbztmRsK3uKJw@mail.gmail.com>
Date:   Thu, 24 Oct 2019 13:27:08 +0800
From:   Chunyan Zhang <zhang.lyra@...il.com>
To:     Chunyan Zhang <chunyan.zhang@...soc.com>
Cc:     Stephen Boyd <sboyd@...nel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        linux-clk <linux-clk@...r.kernel.org>,
        Orson Zhai <orsonzhai@...il.com>,
        Baolin Wang <baolin.wang@...aro.org>,
        Xiaolong Zhang <xiaolong.zhang@...soc.com>
Subject: Re: [PATCH] clk: sprd: change to implement .prepare instead of .enable

Hi,

Please ignore this patch, and sorry for the noise.
I will resend this along with another patch.

Thanks,
Chunyan

On Wed, 16 Oct 2019 at 18:44, Chunyan Zhang <chunyan.zhang@...soc.com> wrote:
>
>
> From: Xiaolong Zhang <xiaolong.zhang@...soc.com>
>
> Some pll_sc_gate clocks need to wait a certain long time for being stable
> after enabled, for this reason enabling this kind of clocks shouldn't be
> done in clk_ops.enable() which would be called at interrupt context. So
> we move the operation to .prepare(), and also hooks to .unprepare() with
> disabling pll_sc_gate clocks.
>
> Signed-off-by: Xiaolong Zhang <xiaolong.zhang@...soc.com>
> Signed-off-by: Chunyan Zhang <chunyan.zhang@...soc.com>
> ---
>  drivers/clk/sprd/gate.c | 8 +++++---
>  1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/clk/sprd/gate.c b/drivers/clk/sprd/gate.c
> index 1491c00575fa..d8b480f852f3 100644
> --- a/drivers/clk/sprd/gate.c
> +++ b/drivers/clk/sprd/gate.c
> @@ -80,7 +80,7 @@ static int sprd_sc_gate_enable(struct clk_hw *hw)
>         return 0;
>  }
>
> -static int sprd_pll_sc_gate_enable(struct clk_hw *hw)
> +static int sprd_pll_sc_gate_prepare(struct clk_hw *hw)
>  {
>         struct sprd_gate *sg = hw_to_sprd_gate(hw);
>
> @@ -120,9 +120,11 @@ const struct clk_ops sprd_sc_gate_ops = {
>  };
>  EXPORT_SYMBOL_GPL(sprd_sc_gate_ops);
>
> +#define sprd_pll_sc_gate_unprepare sprd_sc_gate_disable
> +
>  const struct clk_ops sprd_pll_sc_gate_ops = {
> -       .disable        = sprd_sc_gate_disable,
> -       .enable         = sprd_pll_sc_gate_enable,
> +       .unprepare      = sprd_pll_sc_gate_unprepare,
> +       .prepare        = sprd_pll_sc_gate_prepare,
>         .is_enabled     = sprd_gate_is_enabled,
>  };
>  EXPORT_SYMBOL_GPL(sprd_pll_sc_gate_ops);
> --
> 2.20.1
>
>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ