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] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 6 Sep 2023 00:51:47 +0300
From:   Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
To:     Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>,
        Andy Gross <agross@...nel.org>,
        Bjorn Andersson <andersson@...nel.org>,
        Konrad Dybcio <konrad.dybcio@...aro.org>,
        Rob Herring <robh+dt@...nel.org>,
        Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
        Conor Dooley <conor+dt@...nel.org>,
        linux-arm-msm@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org
Cc:     stable@...r.kernel.org
Subject: Re: [RFT PATCH 1/2] arm64: dts: qcom: apq8096-db820c: fix missing
 clock populate

On 01/09/2023 11:18, Krzysztof Kozlowski wrote:
> Commit 704e26678c8d ("arm64: dts: qcom: apq8096-db820c: drop simple-bus
> from clocks") removed "simple-bus" compatible from "clocks" node, but
> one of the clocks - divclk1 - is a gpio-gate-clock, which does not have
> CLK_OF_DECLARE.  This means it will not be instantiated if placed in
> some subnode.  Move the clocks to the root node, so regular devices will
> be populated.
> 
> Reported-by: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
> Closes: https://lore.kernel.org/all/CAA8EJprF==p87oN+RiwAiNeURF1JcHGfL2Ez5zxqYPRRbN-hhg@mail.gmail.com/
> Cc: <stable@...r.kernel.org>
> Fixes: 704e26678c8d ("arm64: dts: qcom: apq8096-db820c: drop simple-bus from clocks")
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>

Stephen Boyd pointed out that this is a proper way to go (and we should 
unpack remaining /clocks nodes).

Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>
Tested-by: Dmitry Baryshkov <dmitry.baryshkov@...aro.org>

> ---
>   arch/arm64/boot/dts/qcom/apq8096-db820c.dts | 32 ++++++++++-----------
>   1 file changed, 15 insertions(+), 17 deletions(-)
> 
> diff --git a/arch/arm64/boot/dts/qcom/apq8096-db820c.dts b/arch/arm64/boot/dts/qcom/apq8096-db820c.dts
> index 385b178314db..3067a4091a7a 100644
> --- a/arch/arm64/boot/dts/qcom/apq8096-db820c.dts
> +++ b/arch/arm64/boot/dts/qcom/apq8096-db820c.dts
> @@ -62,25 +62,23 @@ chosen {
>   		stdout-path = "serial0:115200n8";
>   	};
>   
> -	clocks {
> -		divclk4: divclk4 {
> -			compatible = "fixed-clock";
> -			#clock-cells = <0>;
> -			clock-frequency = <32768>;
> -			clock-output-names = "divclk4";
> +	div1_mclk: divclk1 {
> +		compatible = "gpio-gate-clock";
> +		pinctrl-0 = <&audio_mclk>;
> +		pinctrl-names = "default";
> +		clocks = <&rpmcc RPM_SMD_DIV_CLK1>;
> +		#clock-cells = <0>;
> +		enable-gpios = <&pm8994_gpios 15 0>;
> +	};
>   
> -			pinctrl-names = "default";
> -			pinctrl-0 = <&divclk4_pin_a>;
> -		};
> +	divclk4: divclk4 {
> +		compatible = "fixed-clock";
> +		#clock-cells = <0>;
> +		clock-frequency = <32768>;
> +		clock-output-names = "divclk4";
>   
> -		div1_mclk: divclk1 {
> -			compatible = "gpio-gate-clock";
> -			pinctrl-0 = <&audio_mclk>;
> -			pinctrl-names = "default";
> -			clocks = <&rpmcc RPM_SMD_DIV_CLK1>;
> -			#clock-cells = <0>;
> -			enable-gpios = <&pm8994_gpios 15 0>;
> -		};
> +		pinctrl-names = "default";
> +		pinctrl-0 = <&divclk4_pin_a>;
>   	};
>   
>   	gpio-keys {

-- 
With best wishes
Dmitry

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ