Message ID | 1436219188-4325-3-git-send-email-wsa@the-dreams.de (mailing list archive) |
---|---|
State | Superseded |
Delegated to: | Geert Uytterhoeven |
Headers | show |
Hi Wolfram, On Mon, Jul 6, 2015 at 11:46 PM, Wolfram Sang <wsa@the-dreams.de> wrote: > diff --git a/Documentation/devicetree/bindings/i2c/i2c-emev2.txt b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > new file mode 100644 > index 00000000000000..a6740066835056 > --- /dev/null > +++ b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > @@ -0,0 +1,22 @@ > +Device tree configuration for Renesas EMEV2 IIC driver > + > +Required properties: > +- compatible : "renesas,iic-<soctype>". "renesas,iic-emev2" as fallback What's the "<soctype>"? Isn't that "emev2"? > +- reg : address start and address range size of device > +- interrupts : 1 interrupt > +- clocks : phandle to the IP core SCLK > +- clock-names : must be "sclk" > +- #address-cells : should be <1> > +- #size-cells : should be <0> > + > +Example: > + > + iic0: i2c@e0070000 { > + #address-cells = <1>; > + #size-cells = <0>; > + compatible = "renesas,iic-emev2"; > + reg = <0xe0070000 0x28>; > + interrupts = <0 32 IRQ_TYPE_EDGE_RISING>; Are you sure about rising edge? All other emev2 interrupts are IRQ_TYPE_LEVEL_HIGH. > + clocks = <&iic0_sclk>; > + clock-names = "sclk"; > + }; Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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 -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On Tue, Jul 07, 2015 at 10:41:37AM +0200, Geert Uytterhoeven wrote: > Hi Wolfram, > > On Mon, Jul 6, 2015 at 11:46 PM, Wolfram Sang <wsa@the-dreams.de> wrote: > > diff --git a/Documentation/devicetree/bindings/i2c/i2c-emev2.txt b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > > new file mode 100644 > > index 00000000000000..a6740066835056 > > --- /dev/null > > +++ b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > > @@ -0,0 +1,22 @@ > > +Device tree configuration for Renesas EMEV2 IIC driver > > + > > +Required properties: > > +- compatible : "renesas,iic-<soctype>". "renesas,iic-emev2" as fallback > > What's the "<soctype>"? Isn't that "emev2"? Hmm, I though emev2 was the family but looking again I might be wrong. But it is still confusing to me. EM (EMMA Mobile) is the family and EV2 is the SoC? I should probably just skip the <soctype> thing above, then it should be good. > > + interrupts = <0 32 IRQ_TYPE_EDGE_RISING>; > > Are you sure about rising edge? All other emev2 interrupts are > IRQ_TYPE_LEVEL_HIGH. Yes. R19UH00356EJ0800_1chip.pdf, chapter 7.1.1 64 IIC0 IIC0_INT IIC #0 interrupt Edge 65 IIC1 IIC1_INT IIC #1 interrupt Edge Thanks, Wolfram
Hi Wolfram, On Tue, Jul 7, 2015 at 11:17 AM, Wolfram Sang <wsa@the-dreams.de> wrote: >> > + interrupts = <0 32 IRQ_TYPE_EDGE_RISING>; >> >> Are you sure about rising edge? All other emev2 interrupts are >> IRQ_TYPE_LEVEL_HIGH. > > Yes. R19UH00356EJ0800_1chip.pdf, chapter 7.1.1 > > 64 > IIC0 > IIC0_INT > IIC #0 interrupt > Edge > 65 > IIC1 > IIC1_INT > IIC #1 interrupt > Edge OK, verified using R19UH0036EJ1600_1chip.pdf (which is newer, Google is your friend). Gr{oetje,eeting}s, Geert -- Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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 -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi Wolfram, Thank you for the patch. On Monday 06 July 2015 23:46:06 Wolfram Sang wrote: > From: Wolfram Sang <wsa+renesas@sang-engineering.com> > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> > --- > .../devicetree/bindings/i2c/i2c-emev2.txt | 22 ++++++++++++++++++ > 1 file changed, 22 insertions(+) > create mode 100644 Documentation/devicetree/bindings/i2c/i2c-emev2.txt > > diff --git a/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt new file mode 100644 > index 00000000000000..a6740066835056 > --- /dev/null > +++ b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt > @@ -0,0 +1,22 @@ > +Device tree configuration for Renesas EMEV2 IIC driver s/driver/controller/ > + > +Required properties: > +- compatible : "renesas,iic-<soctype>". "renesas,iic-emev2" as > fallback > +- reg : address start and address range size of device > +- interrupts : 1 interrupt I'd write this as "specifier for the IIC controller interrupt". > +- clocks : phandle to the IP core SCLK The datasheet mentions PCLK and IIC_SCLK but doesn't provide details. Do you have more information ? > +- clock-names : must be "sclk" > +- #address-cells : should be <1> > +- #size-cells : should be <0> > + > +Example: > + > + iic0: i2c@e0070000 { > + #address-cells = <1>; > + #size-cells = <0>; > + compatible = "renesas,iic-emev2"; > + reg = <0xe0070000 0x28>; > + interrupts = <0 32 IRQ_TYPE_EDGE_RISING>; > + clocks = <&iic0_sclk>; > + clock-names = "sclk"; > + };
> > +Device tree configuration for Renesas EMEV2 IIC driver > > s/driver/controller/ Yes, > > +- interrupts : 1 interrupt > > I'd write this as "specifier for the IIC controller interrupt". Yes. > > > +- clocks : phandle to the IP core SCLK > > The datasheet mentions PCLK and IIC_SCLK but doesn't provide details. Do you > have more information ? I follow what is done for the other EMEV2 IP cores currently supported. All cores I checked have PCLK and SCLK but only SCLK is referenced in the DTS.
Hi Wolfram, On Tuesday 07 July 2015 21:43:13 Wolfram Sang wrote: > > > +Device tree configuration for Renesas EMEV2 IIC driver > > > > s/driver/controller/ > > Yes, > > > > +- interrupts : 1 interrupt > > > > I'd write this as "specifier for the IIC controller interrupt". > > Yes. > > > > +- clocks : phandle to the IP core SCLK > > > > The datasheet mentions PCLK and IIC_SCLK but doesn't provide details. Do > > you have more information ? > > I follow what is done for the other EMEV2 IP cores currently supported. > All cores I checked have PCLK and SCLK but only SCLK is referenced in > the DTS. Could you briefly explain what the two clocks are for ? Or point me to the right documentation ?
> > I follow what is done for the other EMEV2 IP cores currently supported. > > All cores I checked have PCLK and SCLK but only SCLK is referenced in > > the DTS. > > Could you briefly explain what the two clocks are for ? Or point me to the > right documentation ? PCLK is the APB clock. See R19UH0037EJ1200_SMU.pdf, chapter 4.13.
On Tuesday 07 July 2015 21:53:13 Wolfram Sang wrote: > > > I follow what is done for the other EMEV2 IP cores currently supported. > > > All cores I checked have PCLK and SCLK but only SCLK is referenced in > > > the DTS. > > > > Could you briefly explain what the two clocks are for ? Or point me to the > > right documentation ? > > PCLK is the APB clock. See R19UH0037EJ1200_SMU.pdf, chapter 4.13. Is that the functional clock, while SCLK is the clock used to control serial communication ?
> Is that the functional clock, while SCLK is the clock used to control serial > communication ? Yes, that's how I read it.
diff --git a/Documentation/devicetree/bindings/i2c/i2c-emev2.txt b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt new file mode 100644 index 00000000000000..a6740066835056 --- /dev/null +++ b/Documentation/devicetree/bindings/i2c/i2c-emev2.txt @@ -0,0 +1,22 @@ +Device tree configuration for Renesas EMEV2 IIC driver + +Required properties: +- compatible : "renesas,iic-<soctype>". "renesas,iic-emev2" as fallback +- reg : address start and address range size of device +- interrupts : 1 interrupt +- clocks : phandle to the IP core SCLK +- clock-names : must be "sclk" +- #address-cells : should be <1> +- #size-cells : should be <0> + +Example: + + iic0: i2c@e0070000 { + #address-cells = <1>; + #size-cells = <0>; + compatible = "renesas,iic-emev2"; + reg = <0xe0070000 0x28>; + interrupts = <0 32 IRQ_TYPE_EDGE_RISING>; + clocks = <&iic0_sclk>; + clock-names = "sclk"; + };