[PATCH] ARM: dts: rainier: Update to access sensors via iio-hwmon

Joel Stanley joel at jms.id.au
Wed Mar 31 18:48:23 AEDT 2021


On Mon, 29 Mar 2021 at 09:43, Rashmica Gupta <rashmica.g at gmail.com> wrote:
>

Can you add a brief message about why we're adding a iio-hwmon bridge
for these sensors?

> Signed-off-by: Rashmica Gupta <rashmica.g at gmail.com>
> ---
>  arch/arm/boot/dts/aspeed-bmc-ibm-rainier.dts | 13 ++++++++++++-
>  1 file changed, 12 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm/boot/dts/aspeed-bmc-ibm-rainier.dts b/arch/arm/boot/dts/aspeed-bmc-ibm-rainier.dts
> index fefb0b8fd6d5..2dc72de07906 100644
> --- a/arch/arm/boot/dts/aspeed-bmc-ibm-rainier.dts
> +++ b/arch/arm/boot/dts/aspeed-bmc-ibm-rainier.dts
> @@ -173,6 +173,16 @@ i2c2mux3: i2c at 3 {
>                 };
>         };
>
> +       iio-hwmon-dps310 {
> +               compatible = "iio-hwmon";
> +               io-channels = <&dps 0>;
> +       };
> +
> +       iio-hwmon-si7020 {
> +               compatible = "iio-hwmon";
> +               io-channels = <&si 1>;
> +       };
> +
>         leds {
>                 compatible = "gpio-leds";
>
> @@ -1972,9 +1982,10 @@ &i2c7 {
>         multi-master;
>         status = "okay";
>
> -       si7021-a20 at 20 {
> +       si:si7021-a20 at 20 {

That's a very short name. How about we call it humidity (or something else)?

Convention is to put a space after the colon.

>                 compatible = "silabs,si7020";
>                 reg = <0x20>;
> +               #io-channel-cells = <1>;
>         };
>
>         tmp275 at 48 {
> --
> 2.26.3
>


More information about the Linux-aspeed mailing list