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: <20150811232649.31346.37488@quantum>
Date:	Tue, 11 Aug 2015 16:26:49 -0700
From:	Michael Turquette <mturquette@...libre.com>
To:	Alexandre Belloni <alexandre.belloni@...e-electrons.com>,
	"Nicolas Ferre" <nicolas.ferre@...el.com>
Cc:	"Boris Brezillon" <boris.brezillon@...e-electrons.com>,
	"Maxime Ripard" <maxime.ripard@...e-electrons.com>,
	linux-arm-kernel@...ts.infradead.org, linux-kernel@...r.kernel.org,
	"Alexandre Belloni" <alexandre.belloni@...e-electrons.com>,
	"Stephen Boyd" <sboyd@...eaurora.org>, linux-clk@...r.kernel.org
Subject: Re: [PATCH 20/20] clk: at91: Revert "keep slow clk enabled to prevent system
 hang"

Quoting Alexandre Belloni (2015-07-29 17:22:06)
> Commit dca1a4b5ff6e ("clk: at91: keep slow clk enabled to prevent system
> hang") added a workaround for the slow clock as it is not properly handled
> by its users.
> 
> Now that the slow clock is taken properly by the drivers, this workaround
> is not necessary anymore, revert it.
> 
> Signed-off-by: Alexandre Belloni <alexandre.belloni@...e-electrons.com>
> ---
> Cc: Michael Turquette <mturquette@...libre.com>
> Cc: Stephen Boyd <sboyd@...eaurora.org>
> Cc: linux-clk@...r.kernel.org
>  drivers/clk/at91/clk-slow.c | 27 ---------------------------
>  1 file changed, 27 deletions(-)
> 
> diff --git a/drivers/clk/at91/clk-slow.c b/drivers/clk/at91/clk-slow.c
> index 98a84a865fe1..2c59d6a64dd5 100644
> --- a/drivers/clk/at91/clk-slow.c
> +++ b/drivers/clk/at91/clk-slow.c
> @@ -70,7 +70,6 @@ struct clk_sam9x5_slow {
>  
>  #define to_clk_sam9x5_slow(hw) container_of(hw, struct clk_sam9x5_slow, hw)
>  
> -static struct clk *slow_clk;
>  

Might want to remove one extra line of white space?

>  static int clk_slow_osc_prepare(struct clk_hw *hw)
>  {
> @@ -358,8 +357,6 @@ at91_clk_register_sam9x5_slow(void __iomem *sckcr,
>         clk = clk_register(NULL, &slowck->hw);
>         if (IS_ERR(clk))
>                 kfree(slowck);
> -       else
> -               slow_clk = clk;
>  
>         return clk;
>  }
> @@ -436,8 +433,6 @@ at91_clk_register_sam9260_slow(struct at91_pmc *pmc,
>         clk = clk_register(NULL, &slowck->hw);
>         if (IS_ERR(clk))
>                 kfree(slowck);
> -       else
> -               slow_clk = clk;
>  
>         return clk;
>  }
> @@ -470,25 +465,3 @@ void __init of_at91sam9260_clk_slow_setup(struct device_node *np,
>  
>         of_clk_add_provider(np, of_clk_src_simple_get, clk);
>  }
> -
> -/*
> - * FIXME: All slow clk users are not properly claiming it (get + prepare +
> - * enable) before using it.
> - * If all users properly claiming this clock decide that they don't need it
> - * anymore (or are removed), it is disabled while faulty users are still
> - * requiring it, and the system hangs.
> - * Prevent this clock from being disabled until all users are properly
> - * requesting it.
> - * Once this is done we should remove this function and the slow_clk variable.
> - */
> -static int __init of_at91_clk_slow_retain(void)
> -{
> -       if (!slow_clk)
> -               return 0;
> -
> -       __clk_get(slow_clk);
> -       clk_prepare_enable(slow_clk);
> -
> -       return 0;
> -}
> -arch_initcall(of_at91_clk_slow_retain);

This is a cool series. Thanks. Feel free to add my Ack, or we can take
this through clk-next once the other patches are applied.

Regards,
Mike

> -- 
> 2.1.4
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ