linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
@ 2018-07-30 11:18 Marek Vasut
  2018-08-01 12:32 ` Geert Uytterhoeven
  0 siblings, 1 reply; 7+ messages in thread
From: Marek Vasut @ 2018-07-30 11:18 UTC (permalink / raw)
  To: linux-arm-kernel

Add DA9063 PMIC node to the I2C bus.

Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
Cc: Geert Uytterhoeven <geert+renesas@glider.be>
Cc: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com>
Cc: Simon Horman <horms+renesas@verge.net.au>
Cc: Wolfram Sang <wsa+renesas@sang-engineering.com>
Cc: linux-renesas-soc at vger.kernel.org
---
 arch/arm/boot/dts/r8a7794-silk.dts | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/arch/arm/boot/dts/r8a7794-silk.dts b/arch/arm/boot/dts/r8a7794-silk.dts
index daec965889d3..bf7e8ffd1e69 100644
--- a/arch/arm/boot/dts/r8a7794-silk.dts
+++ b/arch/arm/boot/dts/r8a7794-silk.dts
@@ -403,6 +403,18 @@
 	pinctrl-names = "i2c-hdmi";
 
 	clock-frequency = <400000>;
+
+	pmic at 5a {
+		compatible = "dlg,da9063";
+		reg = <0x5a>;
+		interrupt-parent = <&irqc0>;
+		interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
+		interrupt-controller;
+
+		wdt {
+			compatible = "dlg,da9063-watchdog";
+		};
+	};
 };
 
 &mmcif0 {
-- 
2.16.2

^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-07-30 11:18 [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node Marek Vasut
@ 2018-08-01 12:32 ` Geert Uytterhoeven
  2018-08-02 13:55   ` Marek Vasut
  0 siblings, 1 reply; 7+ messages in thread
From: Geert Uytterhoeven @ 2018-08-01 12:32 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Marek,

On Mon, Jul 30, 2018 at 1:18 PM Marek Vasut <marek.vasut@gmail.com> wrote:
> Add DA9063 PMIC node to the I2C bus.
>
> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>

Thanks for your patch!

Oneline-summary prefix should be "ARM: dts: silk:".

> --- a/arch/arm/boot/dts/r8a7794-silk.dts
> +++ b/arch/arm/boot/dts/r8a7794-silk.dts
> @@ -403,6 +403,18 @@
>         pinctrl-names = "i2c-hdmi";
>
>         clock-frequency = <400000>;
> +
> +       pmic at 5a {

Hmm, the da9063 is actually connected to two i2c buses: i2c1 (3.3v)
and i2c7 (1.8v).
On Koelsch, we describe the 1.8v connection, as that i2c bus
("i2c_dvfs") is meant
for power control.

> +               compatible = "dlg,da9063";
> +               reg = <0x5a>;
> +               interrupt-parent = <&irqc0>;
> +               interrupts = <2 IRQ_TYPE_LEVEL_LOW>;

According to my schematics, the interrupt is connected to GP3_31?

> +               interrupt-controller;
> +
> +               wdt {
> +                       compatible = "dlg,da9063-watchdog";
> +               };
> +       };
>  };

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-08-01 12:32 ` Geert Uytterhoeven
@ 2018-08-02 13:55   ` Marek Vasut
  2018-08-02 14:07     ` Geert Uytterhoeven
  0 siblings, 1 reply; 7+ messages in thread
From: Marek Vasut @ 2018-08-02 13:55 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/01/2018 02:32 PM, Geert Uytterhoeven wrote:
> Hi Marek,

Hi,

> On Mon, Jul 30, 2018 at 1:18 PM Marek Vasut <marek.vasut@gmail.com> wrote:
>> Add DA9063 PMIC node to the I2C bus.
>>
>> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
> 
> Thanks for your patch!
> 
> Oneline-summary prefix should be "ARM: dts: silk:".

Right, fixed

>> --- a/arch/arm/boot/dts/r8a7794-silk.dts
>> +++ b/arch/arm/boot/dts/r8a7794-silk.dts
>> @@ -403,6 +403,18 @@
>>         pinctrl-names = "i2c-hdmi";
>>
>>         clock-frequency = <400000>;
>> +
>> +       pmic at 5a {
> 
> Hmm, the da9063 is actually connected to two i2c buses: i2c1 (3.3v)
> and i2c7 (1.8v).
> On Koelsch, we describe the 1.8v connection, as that i2c bus
> ("i2c_dvfs") is meant
> for power control.

On Koelsch, the pmic is sitting on i2c6 only. What am I missing ?

>> +               compatible = "dlg,da9063";
>> +               reg = <0x5a>;
>> +               interrupt-parent = <&irqc0>;
>> +               interrupts = <2 IRQ_TYPE_LEVEL_LOW>;
> 
> According to my schematics, the interrupt is connected to GP3_31?

Yeah, fixed, thanks.

>> +               interrupt-controller;
>> +
>> +               wdt {
>> +                       compatible = "dlg,da9063-watchdog";
>> +               };
>> +       };
>>  };
> 
> Gr{oetje,eeting}s,
> 
>                         Geert
> 


-- 
Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-08-02 13:55   ` Marek Vasut
@ 2018-08-02 14:07     ` Geert Uytterhoeven
  2018-08-03 10:12       ` Marek Vasut
  0 siblings, 1 reply; 7+ messages in thread
From: Geert Uytterhoeven @ 2018-08-02 14:07 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Marek,

On Thu, Aug 2, 2018 at 3:56 PM Marek Vasut <marek.vasut@gmail.com> wrote:
> On 08/01/2018 02:32 PM, Geert Uytterhoeven wrote:
> > On Mon, Jul 30, 2018 at 1:18 PM Marek Vasut <marek.vasut@gmail.com> wrote:
> >> Add DA9063 PMIC node to the I2C bus.
> >>
> >> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
> >
> > Thanks for your patch!
> >
> > Oneline-summary prefix should be "ARM: dts: silk:".
>
> Right, fixed
>
> >> --- a/arch/arm/boot/dts/r8a7794-silk.dts
> >> +++ b/arch/arm/boot/dts/r8a7794-silk.dts
> >> @@ -403,6 +403,18 @@
> >>         pinctrl-names = "i2c-hdmi";
> >>
> >>         clock-frequency = <400000>;
> >> +
> >> +       pmic at 5a {
> >
> > Hmm, the da9063 is actually connected to two i2c buses: i2c1 (3.3v)
> > and i2c7 (1.8v).
> > On Koelsch, we describe the 1.8v connection, as that i2c bus
> > ("i2c_dvfs") is meant
> > for power control.
>
> On Koelsch, the pmic is sitting on i2c6 only. What am I missing ?

On Koelsch, i2c6 is wired to the da9063' 2-wire bus, and i2c1 is wired to
the da9063's HS (high-speed) 2-wire bus.

Wolfram: do you like i2c slaves connected to multiple buses?

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-08-02 14:07     ` Geert Uytterhoeven
@ 2018-08-03 10:12       ` Marek Vasut
  2018-08-03 10:48         ` Wolfram Sang
  0 siblings, 1 reply; 7+ messages in thread
From: Marek Vasut @ 2018-08-03 10:12 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/02/2018 04:07 PM, Geert Uytterhoeven wrote:
> Hi Marek,

Hi,

> On Thu, Aug 2, 2018 at 3:56 PM Marek Vasut <marek.vasut@gmail.com> wrote:
>> On 08/01/2018 02:32 PM, Geert Uytterhoeven wrote:
>>> On Mon, Jul 30, 2018 at 1:18 PM Marek Vasut <marek.vasut@gmail.com> wrote:
>>>> Add DA9063 PMIC node to the I2C bus.
>>>>
>>>> Signed-off-by: Marek Vasut <marek.vasut+renesas@gmail.com>
>>>
>>> Thanks for your patch!
>>>
>>> Oneline-summary prefix should be "ARM: dts: silk:".
>>
>> Right, fixed
>>
>>>> --- a/arch/arm/boot/dts/r8a7794-silk.dts
>>>> +++ b/arch/arm/boot/dts/r8a7794-silk.dts
>>>> @@ -403,6 +403,18 @@
>>>>         pinctrl-names = "i2c-hdmi";
>>>>
>>>>         clock-frequency = <400000>;
>>>> +
>>>> +       pmic at 5a {
>>>
>>> Hmm, the da9063 is actually connected to two i2c buses: i2c1 (3.3v)
>>> and i2c7 (1.8v).
>>> On Koelsch, we describe the 1.8v connection, as that i2c bus
>>> ("i2c_dvfs") is meant
>>> for power control.
>>
>> On Koelsch, the pmic is sitting on i2c6 only. What am I missing ?
> 
> On Koelsch, i2c6 is wired to the da9063' 2-wire bus, and i2c1 is wired to
> the da9063's HS (high-speed) 2-wire bus.

On Silk it's wired to i2c1 and i2c7 apparently, I checked with
i2cdetect/i2cdump that the PMIC responds on both busses, although it has
address 0x5a on i2c1 and 0x58 on i2c7 .

> Wolfram: do you like i2c slaves connected to multiple buses?
> 
> Gr{oetje,eeting}s,
> 
>                         Geert
> 


-- 
Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-08-03 10:12       ` Marek Vasut
@ 2018-08-03 10:48         ` Wolfram Sang
  2018-08-03 11:40           ` Marek Vasut
  0 siblings, 1 reply; 7+ messages in thread
From: Wolfram Sang @ 2018-08-03 10:48 UTC (permalink / raw)
  To: linux-arm-kernel


> > Wolfram: do you like i2c slaves connected to multiple buses?

'Like' would be an exaggeration, but if they are connected to multiple
busses, this might be a reason to describe that. People could then in
userspace bind/unbind to the bus they want? Not pretty, but there might
be reasons for that?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20180803/bc0b119e/attachment.sig>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node
  2018-08-03 10:48         ` Wolfram Sang
@ 2018-08-03 11:40           ` Marek Vasut
  0 siblings, 0 replies; 7+ messages in thread
From: Marek Vasut @ 2018-08-03 11:40 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/03/2018 12:48 PM, Wolfram Sang wrote:
> 
>>> Wolfram: do you like i2c slaves connected to multiple buses?
> 
> 'Like' would be an exaggeration, but if they are connected to multiple
> busses, this might be a reason to describe that. People could then in
> userspace bind/unbind to the bus they want? Not pretty, but there might
> be reasons for that?

Would that be useful for a PMIC ? I suspect it'd create quite a few
problems if the user could move PMIC between I2C busses at will and I
don't see any benefits.

-- 
Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2018-08-03 11:40 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-07-30 11:18 [PATCH] ARM: shmobile: silk: Add DA9063 PMIC node Marek Vasut
2018-08-01 12:32 ` Geert Uytterhoeven
2018-08-02 13:55   ` Marek Vasut
2018-08-02 14:07     ` Geert Uytterhoeven
2018-08-03 10:12       ` Marek Vasut
2018-08-03 10:48         ` Wolfram Sang
2018-08-03 11:40           ` Marek Vasut

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).