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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAD56B7dw4kTRuXeKXyT6KbEP9E=B=KqpamL14d96LjGgAfrbGQ@mail.gmail.com>
Date:   Tue, 21 May 2019 09:26:44 -0400
From:   Paul Thomas <pthomas8589@...il.com>
To:     Manish Narani <manish.narani@...inx.com>
Cc:     jic23@...nel.org, knaack.h@....de, lars@...afoo.de,
        pmeerw@...erw.net, robh+dt@...nel.org, mark.rutland@....com,
        michal.simek@...inx.com, Jisheng.Zhang@...aptics.com,
        olof@...om.net, dinguyen@...nel.org, amit.kucheria@...aro.org,
        stefan.popa@...log.com, dmurphy@...com, marcus.folkesson@...il.com,
        tmaimon77@...il.com, ricardo@...alda.com, xc-racer2@...e.ca,
        contact@...ur-rojek.eu, geert@...ux-m68k.org,
        smohanad@...eaurora.org, charles-antoine.couret@...ensium.com,
        stefan@...er.ch, max.krummenacher@...adex.com,
        lee.jones@...aro.org, linux-iio@...r.kernel.org,
        devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
        linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v4 3/3] arm64: zynqmp: DT: Add Xilinx AMS node

Hi Manish,

Thank you for posting this! It is very much needed in the mainline
kernel, nice work.

On Mon, Apr 22, 2019 at 10:54 AM Manish Narani <manish.narani@...inx.com> wrote:
>
> The Xilinx AMS includes an ADC as well as on-chip sensors that can be
> used to sample external and monitor on-die operating conditions, such as
> temperature and supply voltage levels.
>
> Signed-off-by: Manish Narani <manish.narani@...inx.com>
> ---
>  arch/arm64/boot/dts/xilinx/zynqmp.dtsi | 26 ++++++++++++++++++++++++++
>  1 file changed, 26 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/xilinx/zynqmp.dtsi b/arch/arm64/boot/dts/xilinx/zynqmp.dtsi
> index 9aa6734..f776913 100644
> --- a/arch/arm64/boot/dts/xilinx/zynqmp.dtsi
> +++ b/arch/arm64/boot/dts/xilinx/zynqmp.dtsi
> @@ -625,5 +625,31 @@
>                         reg = <0x0 0xfd4d0000 0x0 0x1000>;
>                         timeout-sec = <10>;
>                 };
> +
> +               xilinx_ams: ams@...50000 {
> +                       compatible = "xlnx,zynqmp-ams";
> +                       status = "disabled";
> +                       interrupt-parent = <&gic>;
> +                       interrupts = <0 56 4>;
> +                       interrupt-names = "ams-irq";
> +                       reg = <0x0 0xffa50000 0x0 0x800>;
> +                       reg-names = "ams-base";
> +                       #address-cells = <1>;
> +                       #size-cells = <1>;
> +                       #io-channel-cells = <1>;
> +                       ranges = <0 0 0xffa50800 0x800>;
> +
> +                       ams_ps: ams-ps@0,0 {
> +                               compatible = "xlnx,zynqmp-ams-ps";
> +                               status = "disabled";
> +                               reg = <0 0x400>;
> +                       };
> +
> +                       ams_pl: ams-pl@1,0 {
> +                               compatible = "xlnx,zynqmp-ams-pl";
> +                               status = "disabled";
> +                               reg = <0x400 0x400>;
> +                       };
> +               };
>         };
>  };
> --
> 2.1.1
>
I tested this with an older 4.18 kernel, and with a slightly different
devicetree (shown below) it seems to be working.

        xilinx_ams: ams@...50000 {
                compatible = "xlnx,zynqmp-ams";
                status = "okay";
                interrupt-parent = <&gic>;
                interrupts = <0 56 4>;
                interrupt-names = "ams-irq";
                reg = <0x0 0xffa50000 0x0 0x800>;
                reg-names = "ams-base";

                #address-cells = <2>;
                #size-cells = <2>;
                ranges;

                ams_ps: ams_ps@...50800 {
                        compatible = "xlnx,zynqmp-ams-ps";
                        reg = <0x0 0xffa50800 0x0 0x400>;
                };

                ams_pl: ams_pl@...50c00 {
                        compatible = "xlnx,zynqmp-ams-pl";
                        reg = <0x0 0xffa50c00 0x0 0x400>;
                };

Also I needed to have the clock defined "clocks = <&clk 70>;".

For the temperatures I get in_temp0_raw, in_temp1_raw and in_temp2 do
these correspond to channels 7,8 & 21 in the devicetree documentation?

thanks,
Paul

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ