Message ID | 1438780706-20945-2-git-send-email-wsa@the-dreams.de (mailing list archive) |
---|---|
State | RFC |
Delegated to: | Geert Uytterhoeven |
Headers | show |
On Wed, Aug 05, 2015 at 03:18:25PM +0200, Wolfram Sang wrote: > From: Wolfram Sang <wsa+renesas@sang-engineering.com> > > Enable the I2C core for this SoC. I add a new type because this version > has new features (e.g. DMA) which will be added somewhen later. Minor nit: s/somewhen/sometime/ or: s/somewhen // > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> > --- > Documentation/devicetree/bindings/i2c/i2c-rcar.txt | 1 + > drivers/i2c/busses/i2c-rcar.c | 3 +++ > 2 files changed, 4 insertions(+) > > diff --git a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > index 16b3e07aa98fdd..ea406eb20fa5ad 100644 > --- a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > +++ b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > @@ -10,6 +10,7 @@ Required properties: > "renesas,i2c-r8a7792" > "renesas,i2c-r8a7793" > "renesas,i2c-r8a7794" > + "renesas,i2c-r8a7795" > - reg: physical base address of the controller and length of memory mapped > region. > - interrupts: interrupt specifier. > diff --git a/drivers/i2c/busses/i2c-rcar.c b/drivers/i2c/busses/i2c-rcar.c > index d8361dada58455..3e125654bb288a 100644 > --- a/drivers/i2c/busses/i2c-rcar.c > +++ b/drivers/i2c/busses/i2c-rcar.c > @@ -103,6 +103,7 @@ > enum rcar_i2c_type { > I2C_RCAR_GEN1, > I2C_RCAR_GEN2, > + I2C_RCAR_GEN3, > }; > > struct rcar_i2c_priv { > @@ -178,6 +179,7 @@ static int rcar_i2c_clock_calculate(struct rcar_i2c_priv *priv, > cdf_width = 2; > break; > case I2C_RCAR_GEN2: > + case I2C_RCAR_GEN3: > cdf_width = 3; > break; > default: > @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = { > { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 }, > { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 }, > { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 }, > + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 }, > {}, > }; > MODULE_DEVICE_TABLE(of, rcar_i2c_dt_ids); > -- > 2.1.4 > > -- > 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 > -- 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 Wednesday 05 August 2015 15:18:25 Wolfram Sang wrote: > From: Wolfram Sang <wsa+renesas@sang-engineering.com> > > Enable the I2C core for this SoC. I add a new type because this version > has new features (e.g. DMA) which will be added somewhen later. > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> > --- > Documentation/devicetree/bindings/i2c/i2c-rcar.txt | 1 + > drivers/i2c/busses/i2c-rcar.c | 3 +++ > 2 files changed, 4 insertions(+) > > diff --git a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt index > 16b3e07aa98fdd..ea406eb20fa5ad 100644 > --- a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > +++ b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt > @@ -10,6 +10,7 @@ Required properties: > "renesas,i2c-r8a7792" > "renesas,i2c-r8a7793" > "renesas,i2c-r8a7794" > + "renesas,i2c-r8a7795" > - reg: physical base address of the controller and length of memory mapped > region. > - interrupts: interrupt specifier. > diff --git a/drivers/i2c/busses/i2c-rcar.c b/drivers/i2c/busses/i2c-rcar.c > index d8361dada58455..3e125654bb288a 100644 > --- a/drivers/i2c/busses/i2c-rcar.c > +++ b/drivers/i2c/busses/i2c-rcar.c > @@ -103,6 +103,7 @@ > enum rcar_i2c_type { > I2C_RCAR_GEN1, > I2C_RCAR_GEN2, > + I2C_RCAR_GEN3, > }; > > struct rcar_i2c_priv { > @@ -178,6 +179,7 @@ static int rcar_i2c_clock_calculate(struct rcar_i2c_priv > *priv, cdf_width = 2; > break; > case I2C_RCAR_GEN2: > + case I2C_RCAR_GEN3: > cdf_width = 3; > break; > default: > @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = { > { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 }, > { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 }, > { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 }, > + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 }, If H3 is compatible with Gen2, can't you just use I2C_RCAR_GEN2 here ? You can always add I2C_RCAR_GEN3 later if you find differences. > {}, > }; > MODULE_DEVICE_TABLE(of, rcar_i2c_dt_ids);
On Thu, Aug 06, 2015 at 03:34:05AM +0300, Laurent Pinchart wrote: > Hi Wolfram, > > Thank you for the patch. > > On Wednesday 05 August 2015 15:18:25 Wolfram Sang wrote: > > From: Wolfram Sang <wsa+renesas@sang-engineering.com> > > > > Enable the I2C core for this SoC. I add a new type because this version > > has new features (e.g. DMA) which will be added somewhen later. > > > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> ... > > @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = { > > { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 }, > > { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 }, > > { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 }, > > + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 }, > > If H3 is compatible with Gen2, can't you just use I2C_RCAR_GEN2 here ? You can > always add I2C_RCAR_GEN3 later if you find differences. Is the patch description not clear enough?
On Thursday 06 August 2015 02:38:49 Wolfram Sang wrote: > On Thu, Aug 06, 2015 at 03:34:05AM +0300, Laurent Pinchart wrote: > > Hi Wolfram, > > > > Thank you for the patch. > > > > On Wednesday 05 August 2015 15:18:25 Wolfram Sang wrote: > > > From: Wolfram Sang <wsa+renesas@sang-engineering.com> > > > > > > Enable the I2C core for this SoC. I add a new type because this version > > > has new features (e.g. DMA) which will be added somewhen later. > > > > > > Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com> > > ... > > > > @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = > > > { > > > { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 > > > }, > > > { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 > > > }, > > > { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 > > > }, > > > + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 > > > }, > > > > If H3 is compatible with Gen2, can't you just use I2C_RCAR_GEN2 here ? You > > can always add I2C_RCAR_GEN3 later if you find differences. > > Is the patch description not clear enough? My bad. I should go to bed. And so should you by the way ;-)
> My bad. I should go to bed. And so should you by the way ;-) Acked-by: Wolfram Sang <wsa@the-dreams.de>
diff --git a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt index 16b3e07aa98fdd..ea406eb20fa5ad 100644 --- a/Documentation/devicetree/bindings/i2c/i2c-rcar.txt +++ b/Documentation/devicetree/bindings/i2c/i2c-rcar.txt @@ -10,6 +10,7 @@ Required properties: "renesas,i2c-r8a7792" "renesas,i2c-r8a7793" "renesas,i2c-r8a7794" + "renesas,i2c-r8a7795" - reg: physical base address of the controller and length of memory mapped region. - interrupts: interrupt specifier. diff --git a/drivers/i2c/busses/i2c-rcar.c b/drivers/i2c/busses/i2c-rcar.c index d8361dada58455..3e125654bb288a 100644 --- a/drivers/i2c/busses/i2c-rcar.c +++ b/drivers/i2c/busses/i2c-rcar.c @@ -103,6 +103,7 @@ enum rcar_i2c_type { I2C_RCAR_GEN1, I2C_RCAR_GEN2, + I2C_RCAR_GEN3, }; struct rcar_i2c_priv { @@ -178,6 +179,7 @@ static int rcar_i2c_clock_calculate(struct rcar_i2c_priv *priv, cdf_width = 2; break; case I2C_RCAR_GEN2: + case I2C_RCAR_GEN3: cdf_width = 3; break; default: @@ -625,6 +627,7 @@ static const struct of_device_id rcar_i2c_dt_ids[] = { { .compatible = "renesas,i2c-r8a7792", .data = (void *)I2C_RCAR_GEN2 }, { .compatible = "renesas,i2c-r8a7793", .data = (void *)I2C_RCAR_GEN2 }, { .compatible = "renesas,i2c-r8a7794", .data = (void *)I2C_RCAR_GEN2 }, + { .compatible = "renesas,i2c-r8a7795", .data = (void *)I2C_RCAR_GEN3 }, {}, }; MODULE_DEVICE_TABLE(of, rcar_i2c_dt_ids);