2013-07-10 11:30:50

by Wei Ni

[permalink] [raw]
Subject: [PATCH v2 0/2] Enable lm90 in Tegra30 and Tegra114.

Enable thermal sensor lm90 for Tegra30 Cardhu and Tegra114 Dalmore.

This series is v2, previous version patches:
[RFC 1/9]: http://thread.gmane.org/gmane.linux.power-management.general/31056
[v1]: http://thread.gmane.org/gmane.linux.ports.tegra/11713/

Changes from v1:
1. add vendor strings "onnn" for nct1008 node.

Changes from RFC:
1. Enable it for Tegra114 Dalmore.

Wei Ni (2):
ARM: dt: t30 cardhu: add dt entry for nct1008
ARM: dt: t114 dalmore: add dt entry for nct1008

arch/arm/boot/dts/tegra114-dalmore.dts | 7 +++++++
arch/arm/boot/dts/tegra30-cardhu.dtsi | 7 +++++++
2 files changed, 14 insertions(+)

--
1.7.9.5


2013-07-10 11:30:47

by Wei Ni

[permalink] [raw]
Subject: [PATCH v2 2/2] ARM: dt: t114 dalmore: add dt entry for nct1008

Enable thermal sensor nct1008 for t114 dalmore.

Signed-off-by: Wei Ni <[email protected]>
---
arch/arm/boot/dts/tegra114-dalmore.dts | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/arch/arm/boot/dts/tegra114-dalmore.dts b/arch/arm/boot/dts/tegra114-dalmore.dts
index cb640eb..95c5079 100644
--- a/arch/arm/boot/dts/tegra114-dalmore.dts
+++ b/arch/arm/boot/dts/tegra114-dalmore.dts
@@ -738,6 +738,13 @@
realtek,ldo1-en-gpios =
<&gpio TEGRA_GPIO(V, 3) GPIO_ACTIVE_HIGH>;
};
+
+ nct1008: nct1008 {
+ compatible = "onnn,nct1008";
+ reg = <0x4c>;
+ interrupt-parent = <&gpio>;
+ interrupts = <TEGRA_GPIO(O, 4) IRQ_TYPE_LEVEL_LOW>;
+ };
};

i2c@7000d000 {
--
1.7.9.5

2013-07-10 11:30:53

by Wei Ni

[permalink] [raw]
Subject: [PATCH v2 1/2] ARM: dt: t30 cardhu: add dt entry for nct1008

Enable thermal sensor nct1008 for t30 cardhu.

Signed-off-by: Wei Ni <[email protected]>
---
arch/arm/boot/dts/tegra30-cardhu.dtsi | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/arch/arm/boot/dts/tegra30-cardhu.dtsi b/arch/arm/boot/dts/tegra30-cardhu.dtsi
index f65b53d..3d568a1 100644
--- a/arch/arm/boot/dts/tegra30-cardhu.dtsi
+++ b/arch/arm/boot/dts/tegra30-cardhu.dtsi
@@ -286,6 +286,13 @@
};
};
};
+
+ nct1008: nct1008 {
+ compatible = "onnn,nct1008";
+ reg = <0x4c>;
+ interrupt-parent = <&gpio>;
+ interrupts = <TEGRA_GPIO(CC, 2) IRQ_TYPE_LEVEL_LOW>;
+ };
};

spi@7000da00 {
--
1.7.9.5

2013-07-10 17:13:29

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] ARM: dt: t30 cardhu: add dt entry for nct1008

On Wed, Jul 10, 2013 at 07:29:57PM +0800, Wei Ni wrote:
> Enable thermal sensor nct1008 for t30 cardhu.

Nit: "Tegra30 Cardhu"

> diff --git a/arch/arm/boot/dts/tegra30-cardhu.dtsi b/arch/arm/boot/dts/tegra30-cardhu.dtsi
[...]
> };
> };
> };
> +
> + nct1008: nct1008 {

I don't think it's very likely that this chip will need to be referenced
by a phandle, in which case the "nct1008:" label can be dropped. Even if
it was used at some point in the future, it's better to add it at that
time.

Thierry


Attachments:
(No filename) (515.00 B)
signature.asc (836.00 B)
Digital signature
Download all attachments

2013-07-10 17:14:31

by Thierry Reding

[permalink] [raw]
Subject: Re: [PATCH v2 2/2] ARM: dt: t114 dalmore: add dt entry for nct1008

On Wed, Jul 10, 2013 at 07:29:58PM +0800, Wei Ni wrote:
> Enable thermal sensor nct1008 for t114 dalmore.

Nit: "Tegra114 Dalmore"

> diff --git a/arch/arm/boot/dts/tegra114-dalmore.dts b/arch/arm/boot/dts/tegra114-dalmore.dts
[...]
> + nct1008: nct1008 {
> + compatible = "onnn,nct1008";
> + reg = <0x4c>;
> + interrupt-parent = <&gpio>;
> + interrupts = <TEGRA_GPIO(O, 4) IRQ_TYPE_LEVEL_LOW>;
> + };

The "nct1008:" label isn't needed here either.

Thierry


Attachments:
(No filename) (469.00 B)
signature.asc (836.00 B)
Digital signature
Download all attachments

2013-07-11 08:36:34

by Wei Ni

[permalink] [raw]
Subject: Re: [PATCH v2 1/2] ARM: dt: t30 cardhu: add dt entry for nct1008

On 07/11/2013 01:13 AM, Thierry Reding wrote:
> * PGP Signed by an unknown key
>
> On Wed, Jul 10, 2013 at 07:29:57PM +0800, Wei Ni wrote:
>> Enable thermal sensor nct1008 for t30 cardhu.
>
> Nit: "Tegra30 Cardhu"
>
>> diff --git a/arch/arm/boot/dts/tegra30-cardhu.dtsi b/arch/arm/boot/dts/tegra30-cardhu.dtsi
> [...]
>> };
>> };
>> };
>> +
>> + nct1008: nct1008 {
>
> I don't think it's very likely that this chip will need to be referenced
> by a phandle, in which case the "nct1008:" label can be dropped. Even if
> it was used at some point in the future, it's better to add it at that
> time.

Ok, I will remove it.

In the future, I may use this node in the thermal framework, something like:
thermal_zone {
sensor = <&nct1008>;
cooling = <&xxxx>;
....
}
So, at that time I will try to add it again.

Thanks.
Wei.

>
> Thierry
>
> * Unknown Key
> * 0x7F3EB3A1
>