All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH RESEND 0/2] mfd: twl6040: bulk access fix and pdmclk registration
@ 2016-08-31 11:46 ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

Hi,

The two patch were part of a bigger series to support the external pdmclk clock
needed by the McPDM on OMAP4/5 [1].

The other patches have been applied, but the ASoC patch to actually use the
pdmclk needed to be reverted as the MFD parts were not taken.

[1] https://lkml.org/lkml/2016/5/18/299

Regards,
Peter
---
Peter Ujfalusi (2):
  mfd: twl6040: The chip does not support bulk access
  mfd: twl6040: Register child device for twl6040-pdmclk

 Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
 drivers/mfd/twl6040.c                             | 6 ++++++
 include/linux/mfd/twl6040.h                       | 2 +-
 3 files changed, 8 insertions(+), 1 deletion(-)

--
2.9.3

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

* [PATCH RESEND 0/2] mfd: twl6040: bulk access fix and pdmclk registration
@ 2016-08-31 11:46 ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

Hi,

The two patch were part of a bigger series to support the external pdmclk clock
needed by the McPDM on OMAP4/5 [1].

The other patches have been applied, but the ASoC patch to actually use the
pdmclk needed to be reverted as the MFD parts were not taken.

[1] https://lkml.org/lkml/2016/5/18/299

Regards,
Peter
---
Peter Ujfalusi (2):
  mfd: twl6040: The chip does not support bulk access
  mfd: twl6040: Register child device for twl6040-pdmclk

 Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
 drivers/mfd/twl6040.c                             | 6 ++++++
 include/linux/mfd/twl6040.h                       | 2 +-
 3 files changed, 8 insertions(+), 1 deletion(-)

--
2.9.3

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

* [PATCH RESEND 1/2] mfd: twl6040: The chip does not support bulk access
  2016-08-31 11:46 ` Peter Ujfalusi
@ 2016-08-31 11:46   ` Peter Ujfalusi
  -1 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

Bulk access is not working with twl6040, we need to use single register
access. Bulk access would happen when we try to sync the regcache after
power on.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
 drivers/mfd/twl6040.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
index ab328ec49353..c3ad59ef43dd 100644
--- a/drivers/mfd/twl6040.c
+++ b/drivers/mfd/twl6040.c
@@ -609,6 +609,7 @@ static const struct regmap_config twl6040_regmap_config = {
 	.writeable_reg = twl6040_writeable_reg,
 
 	.cache_type = REGCACHE_RBTREE,
+	.use_single_rw = true,
 };
 
 static const struct regmap_irq twl6040_irqs[] = {
-- 
2.9.3

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

* [PATCH RESEND 1/2] mfd: twl6040: The chip does not support bulk access
@ 2016-08-31 11:46   ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

Bulk access is not working with twl6040, we need to use single register
access. Bulk access would happen when we try to sync the regcache after
power on.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
---
 drivers/mfd/twl6040.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
index ab328ec49353..c3ad59ef43dd 100644
--- a/drivers/mfd/twl6040.c
+++ b/drivers/mfd/twl6040.c
@@ -609,6 +609,7 @@ static const struct regmap_config twl6040_regmap_config = {
 	.writeable_reg = twl6040_writeable_reg,
 
 	.cache_type = REGCACHE_RBTREE,
+	.use_single_rw = true,
 };
 
 static const struct regmap_irq twl6040_irqs[] = {
-- 
2.9.3

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

* [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
  2016-08-31 11:46 ` Peter Ujfalusi
@ 2016-08-31 11:46   ` Peter Ujfalusi
  -1 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
The twl6040-pdmclk driver provides a clock which can be used to make sure
that the pdmclk is active when the McPDM is in use.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Rob Herring <robh@kernel.org>
---
 Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
 drivers/mfd/twl6040.c                             | 5 +++++
 include/linux/mfd/twl6040.h                       | 2 +-
 3 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
index e6afdfa3543d..9a98ee7c323d 100644
--- a/Documentation/devicetree/bindings/mfd/twl6040.txt
+++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
@@ -12,6 +12,7 @@ Required properties:
 - interrupt-parent: The parent interrupt controller
 - gpio-controller:
 - #gpio-cells = <1>: twl6040 provides GPO lines.
+- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
 - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
 
 - vio-supply: Regulator for the twl6040 VIO supply
diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
index c3ad59ef43dd..d66502d36ba0 100644
--- a/drivers/mfd/twl6040.c
+++ b/drivers/mfd/twl6040.c
@@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
 	cell->name = "twl6040-gpo";
 	children++;
 
+	/* PDM clock support  */
+	cell = &twl6040->cells[children];
+	cell->name = "twl6040-pdmclk";
+	children++;
+
 	/* The chip is powered down so mark regmap to cache only and dirty */
 	regcache_cache_only(twl6040->regmap, true);
 	regcache_mark_dirty(twl6040->regmap);
diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
index 36795a1be479..a2e88761c09f 100644
--- a/include/linux/mfd/twl6040.h
+++ b/include/linux/mfd/twl6040.h
@@ -168,7 +168,7 @@
 #define TWL6040_VIBROCDET		0x20
 #define TWL6040_TSHUTDET                0x40
 
-#define TWL6040_CELLS			3
+#define TWL6040_CELLS			4
 
 #define TWL6040_REV_ES1_0		0x00
 #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */
-- 
2.9.3

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

* [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
@ 2016-08-31 11:46   ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-08-31 11:46 UTC (permalink / raw)
  To: lee.jones; +Cc: linux-omap, linux-kernel

The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
The twl6040-pdmclk driver provides a clock which can be used to make sure
that the pdmclk is active when the McPDM is in use.

Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Acked-by: Rob Herring <robh@kernel.org>
---
 Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
 drivers/mfd/twl6040.c                             | 5 +++++
 include/linux/mfd/twl6040.h                       | 2 +-
 3 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
index e6afdfa3543d..9a98ee7c323d 100644
--- a/Documentation/devicetree/bindings/mfd/twl6040.txt
+++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
@@ -12,6 +12,7 @@ Required properties:
 - interrupt-parent: The parent interrupt controller
 - gpio-controller:
 - #gpio-cells = <1>: twl6040 provides GPO lines.
+- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
 - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
 
 - vio-supply: Regulator for the twl6040 VIO supply
diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
index c3ad59ef43dd..d66502d36ba0 100644
--- a/drivers/mfd/twl6040.c
+++ b/drivers/mfd/twl6040.c
@@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
 	cell->name = "twl6040-gpo";
 	children++;
 
+	/* PDM clock support  */
+	cell = &twl6040->cells[children];
+	cell->name = "twl6040-pdmclk";
+	children++;
+
 	/* The chip is powered down so mark regmap to cache only and dirty */
 	regcache_cache_only(twl6040->regmap, true);
 	regcache_mark_dirty(twl6040->regmap);
diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
index 36795a1be479..a2e88761c09f 100644
--- a/include/linux/mfd/twl6040.h
+++ b/include/linux/mfd/twl6040.h
@@ -168,7 +168,7 @@
 #define TWL6040_VIBROCDET		0x20
 #define TWL6040_TSHUTDET                0x40
 
-#define TWL6040_CELLS			3
+#define TWL6040_CELLS			4
 
 #define TWL6040_REV_ES1_0		0x00
 #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */
-- 
2.9.3

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

* Re: [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
  2016-08-31 11:46   ` Peter Ujfalusi
  (?)
@ 2016-08-31 14:38   ` Lee Jones
  -1 siblings, 0 replies; 12+ messages in thread
From: Lee Jones @ 2016-08-31 14:38 UTC (permalink / raw)
  To: Peter Ujfalusi; +Cc: linux-omap, linux-kernel

On Wed, 31 Aug 2016, Peter Ujfalusi wrote:

> The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
> The twl6040-pdmclk driver provides a clock which can be used to make sure
> that the pdmclk is active when the McPDM is in use.
> 
> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> Acked-by: Rob Herring <robh@kernel.org>
> ---
>  Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
>  drivers/mfd/twl6040.c                             | 5 +++++
>  include/linux/mfd/twl6040.h                       | 2 +-
>  3 files changed, 7 insertions(+), 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
> index e6afdfa3543d..9a98ee7c323d 100644
> --- a/Documentation/devicetree/bindings/mfd/twl6040.txt
> +++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
> @@ -12,6 +12,7 @@ Required properties:
>  - interrupt-parent: The parent interrupt controller
>  - gpio-controller:
>  - #gpio-cells = <1>: twl6040 provides GPO lines.
> +- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
>  - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
>  
>  - vio-supply: Regulator for the twl6040 VIO supply
> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
> index c3ad59ef43dd..d66502d36ba0 100644
> --- a/drivers/mfd/twl6040.c
> +++ b/drivers/mfd/twl6040.c
> @@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
>  	cell->name = "twl6040-gpo";
>  	children++;
>  
> +	/* PDM clock support  */
> +	cell = &twl6040->cells[children];
> +	cell->name = "twl6040-pdmclk";
> +	children++;

What an awful way of adding cells.

That wouldn't happen in my day! ;)

But ... it fits in with the current way of doing things, so:

For my own reference:
  Acked-by: Lee Jones <lee.jones@linaro.org>

>  	/* The chip is powered down so mark regmap to cache only and dirty */
>  	regcache_cache_only(twl6040->regmap, true);
>  	regcache_mark_dirty(twl6040->regmap);
> diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
> index 36795a1be479..a2e88761c09f 100644
> --- a/include/linux/mfd/twl6040.h
> +++ b/include/linux/mfd/twl6040.h
> @@ -168,7 +168,7 @@
>  #define TWL6040_VIBROCDET		0x20
>  #define TWL6040_TSHUTDET                0x40
>  
> -#define TWL6040_CELLS			3
> +#define TWL6040_CELLS			4
>  
>  #define TWL6040_REV_ES1_0		0x00
>  #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

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

* Re: [PATCH RESEND 1/2] mfd: twl6040: The chip does not support bulk access
  2016-08-31 11:46   ` Peter Ujfalusi
  (?)
@ 2016-08-31 14:39   ` Lee Jones
  -1 siblings, 0 replies; 12+ messages in thread
From: Lee Jones @ 2016-08-31 14:39 UTC (permalink / raw)
  To: Peter Ujfalusi; +Cc: linux-omap, linux-kernel

On Wed, 31 Aug 2016, Peter Ujfalusi wrote:

> Bulk access is not working with twl6040, we need to use single register
> access. Bulk access would happen when we try to sync the regcache after
> power on.
> 
> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> ---
>  drivers/mfd/twl6040.c | 1 +
>  1 file changed, 1 insertion(+)

Applied, thanks.

> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
> index ab328ec49353..c3ad59ef43dd 100644
> --- a/drivers/mfd/twl6040.c
> +++ b/drivers/mfd/twl6040.c
> @@ -609,6 +609,7 @@ static const struct regmap_config twl6040_regmap_config = {
>  	.writeable_reg = twl6040_writeable_reg,
>  
>  	.cache_type = REGCACHE_RBTREE,
> +	.use_single_rw = true,
>  };
>  
>  static const struct regmap_irq twl6040_irqs[] = {

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

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

* Re: [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
  2016-08-31 11:46   ` Peter Ujfalusi
  (?)
  (?)
@ 2016-08-31 14:39   ` Lee Jones
  2016-09-27  8:14       ` Peter Ujfalusi
  -1 siblings, 1 reply; 12+ messages in thread
From: Lee Jones @ 2016-08-31 14:39 UTC (permalink / raw)
  To: Peter Ujfalusi; +Cc: linux-omap, linux-kernel

On Wed, 31 Aug 2016, Peter Ujfalusi wrote:

> The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
> The twl6040-pdmclk driver provides a clock which can be used to make sure
> that the pdmclk is active when the McPDM is in use.
> 
> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> Acked-by: Rob Herring <robh@kernel.org>
> ---
>  Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
>  drivers/mfd/twl6040.c                             | 5 +++++
>  include/linux/mfd/twl6040.h                       | 2 +-
>  3 files changed, 7 insertions(+), 1 deletion(-)

Applied, thanks.

> diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
> index e6afdfa3543d..9a98ee7c323d 100644
> --- a/Documentation/devicetree/bindings/mfd/twl6040.txt
> +++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
> @@ -12,6 +12,7 @@ Required properties:
>  - interrupt-parent: The parent interrupt controller
>  - gpio-controller:
>  - #gpio-cells = <1>: twl6040 provides GPO lines.
> +- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
>  - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
>  
>  - vio-supply: Regulator for the twl6040 VIO supply
> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
> index c3ad59ef43dd..d66502d36ba0 100644
> --- a/drivers/mfd/twl6040.c
> +++ b/drivers/mfd/twl6040.c
> @@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
>  	cell->name = "twl6040-gpo";
>  	children++;
>  
> +	/* PDM clock support  */
> +	cell = &twl6040->cells[children];
> +	cell->name = "twl6040-pdmclk";
> +	children++;
> +
>  	/* The chip is powered down so mark regmap to cache only and dirty */
>  	regcache_cache_only(twl6040->regmap, true);
>  	regcache_mark_dirty(twl6040->regmap);
> diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
> index 36795a1be479..a2e88761c09f 100644
> --- a/include/linux/mfd/twl6040.h
> +++ b/include/linux/mfd/twl6040.h
> @@ -168,7 +168,7 @@
>  #define TWL6040_VIBROCDET		0x20
>  #define TWL6040_TSHUTDET                0x40
>  
> -#define TWL6040_CELLS			3
> +#define TWL6040_CELLS			4
>  
>  #define TWL6040_REV_ES1_0		0x00
>  #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

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

* Re: [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
  2016-08-31 14:39   ` Lee Jones
@ 2016-09-27  8:14       ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-09-27  8:14 UTC (permalink / raw)
  To: Lee Jones; +Cc: linux-omap, linux-kernel

On 08/31/16 17:39, Lee Jones wrote:
> On Wed, 31 Aug 2016, Peter Ujfalusi wrote:
> 
>> The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
>> The twl6040-pdmclk driver provides a clock which can be used to make sure
>> that the pdmclk is active when the McPDM is in use.
>>
>> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
>> Acked-by: Rob Herring <robh@kernel.org>
>> ---
>>  Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
>>  drivers/mfd/twl6040.c                             | 5 +++++
>>  include/linux/mfd/twl6040.h                       | 2 +-
>>  3 files changed, 7 insertions(+), 1 deletion(-)
> 
> Applied, thanks.

Lee, for some reason this patch is not found in linux-next (20160927). I can
see patch 1, but this one is missing.

-- 
Péter


>> diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
>> index e6afdfa3543d..9a98ee7c323d 100644
>> --- a/Documentation/devicetree/bindings/mfd/twl6040.txt
>> +++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
>> @@ -12,6 +12,7 @@ Required properties:
>>  - interrupt-parent: The parent interrupt controller
>>  - gpio-controller:
>>  - #gpio-cells = <1>: twl6040 provides GPO lines.
>> +- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
>>  - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
>>  
>>  - vio-supply: Regulator for the twl6040 VIO supply
>> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
>> index c3ad59ef43dd..d66502d36ba0 100644
>> --- a/drivers/mfd/twl6040.c
>> +++ b/drivers/mfd/twl6040.c
>> @@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
>>  	cell->name = "twl6040-gpo";
>>  	children++;
>>  
>> +	/* PDM clock support  */
>> +	cell = &twl6040->cells[children];
>> +	cell->name = "twl6040-pdmclk";
>> +	children++;
>> +
>>  	/* The chip is powered down so mark regmap to cache only and dirty */
>>  	regcache_cache_only(twl6040->regmap, true);
>>  	regcache_mark_dirty(twl6040->regmap);
>> diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
>> index 36795a1be479..a2e88761c09f 100644
>> --- a/include/linux/mfd/twl6040.h
>> +++ b/include/linux/mfd/twl6040.h
>> @@ -168,7 +168,7 @@
>>  #define TWL6040_VIBROCDET		0x20
>>  #define TWL6040_TSHUTDET                0x40
>>  
>> -#define TWL6040_CELLS			3
>> +#define TWL6040_CELLS			4
>>  
>>  #define TWL6040_REV_ES1_0		0x00
>>  #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */
> 

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

* Re: [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
@ 2016-09-27  8:14       ` Peter Ujfalusi
  0 siblings, 0 replies; 12+ messages in thread
From: Peter Ujfalusi @ 2016-09-27  8:14 UTC (permalink / raw)
  To: Lee Jones; +Cc: linux-omap, linux-kernel

On 08/31/16 17:39, Lee Jones wrote:
> On Wed, 31 Aug 2016, Peter Ujfalusi wrote:
> 
>> The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
>> The twl6040-pdmclk driver provides a clock which can be used to make sure
>> that the pdmclk is active when the McPDM is in use.
>>
>> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
>> Acked-by: Rob Herring <robh@kernel.org>
>> ---
>>  Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
>>  drivers/mfd/twl6040.c                             | 5 +++++
>>  include/linux/mfd/twl6040.h                       | 2 +-
>>  3 files changed, 7 insertions(+), 1 deletion(-)
> 
> Applied, thanks.

Lee, for some reason this patch is not found in linux-next (20160927). I can
see patch 1, but this one is missing.

-- 
Péter


>> diff --git a/Documentation/devicetree/bindings/mfd/twl6040.txt b/Documentation/devicetree/bindings/mfd/twl6040.txt
>> index e6afdfa3543d..9a98ee7c323d 100644
>> --- a/Documentation/devicetree/bindings/mfd/twl6040.txt
>> +++ b/Documentation/devicetree/bindings/mfd/twl6040.txt
>> @@ -12,6 +12,7 @@ Required properties:
>>  - interrupt-parent: The parent interrupt controller
>>  - gpio-controller:
>>  - #gpio-cells = <1>: twl6040 provides GPO lines.
>> +- #clock-cells = <0>; twl6040 is a provider of pdmclk which is used by McPDM
>>  - twl6040,audpwron-gpio: Power on GPIO line for the twl6040
>>  
>>  - vio-supply: Regulator for the twl6040 VIO supply
>> diff --git a/drivers/mfd/twl6040.c b/drivers/mfd/twl6040.c
>> index c3ad59ef43dd..d66502d36ba0 100644
>> --- a/drivers/mfd/twl6040.c
>> +++ b/drivers/mfd/twl6040.c
>> @@ -783,6 +783,11 @@ static int twl6040_probe(struct i2c_client *client,
>>  	cell->name = "twl6040-gpo";
>>  	children++;
>>  
>> +	/* PDM clock support  */
>> +	cell = &twl6040->cells[children];
>> +	cell->name = "twl6040-pdmclk";
>> +	children++;
>> +
>>  	/* The chip is powered down so mark regmap to cache only and dirty */
>>  	regcache_cache_only(twl6040->regmap, true);
>>  	regcache_mark_dirty(twl6040->regmap);
>> diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h
>> index 36795a1be479..a2e88761c09f 100644
>> --- a/include/linux/mfd/twl6040.h
>> +++ b/include/linux/mfd/twl6040.h
>> @@ -168,7 +168,7 @@
>>  #define TWL6040_VIBROCDET		0x20
>>  #define TWL6040_TSHUTDET                0x40
>>  
>> -#define TWL6040_CELLS			3
>> +#define TWL6040_CELLS			4
>>  
>>  #define TWL6040_REV_ES1_0		0x00
>>  #define TWL6040_REV_ES1_1		0x01 /* Rev ES1.1 and ES1.2 */
> 

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

* Re: [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk
  2016-09-27  8:14       ` Peter Ujfalusi
  (?)
@ 2016-09-27 18:50       ` Lee Jones
  -1 siblings, 0 replies; 12+ messages in thread
From: Lee Jones @ 2016-09-27 18:50 UTC (permalink / raw)
  To: Peter Ujfalusi; +Cc: linux-omap, linux-kernel

On Tue, 27 Sep 2016, Peter Ujfalusi wrote:

> On 08/31/16 17:39, Lee Jones wrote:
> > On Wed, 31 Aug 2016, Peter Ujfalusi wrote:
> > 
> >> The McPDM in OMAP4/5 is using the pdmclk from twl6040 as functional clock.
> >> The twl6040-pdmclk driver provides a clock which can be used to make sure
> >> that the pdmclk is active when the McPDM is in use.
> >>
> >> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
> >> Acked-by: Rob Herring <robh@kernel.org>
> >> ---
> >>  Documentation/devicetree/bindings/mfd/twl6040.txt | 1 +
> >>  drivers/mfd/twl6040.c                             | 5 +++++
> >>  include/linux/mfd/twl6040.h                       | 2 +-
> >>  3 files changed, 7 insertions(+), 1 deletion(-)
> > 
> > Applied, thanks.
> 
> Lee, for some reason this patch is not found in linux-next (20160927). I can
> see patch 1, but this one is missing.

You're right, it had been dropped.  My apologies.

It's been applied now.

-- 
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog

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

end of thread, other threads:[~2016-09-27 18:48 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-31 11:46 [PATCH RESEND 0/2] mfd: twl6040: bulk access fix and pdmclk registration Peter Ujfalusi
2016-08-31 11:46 ` Peter Ujfalusi
2016-08-31 11:46 ` [PATCH RESEND 1/2] mfd: twl6040: The chip does not support bulk access Peter Ujfalusi
2016-08-31 11:46   ` Peter Ujfalusi
2016-08-31 14:39   ` Lee Jones
2016-08-31 11:46 ` [PATCH RESEND 2/2] mfd: twl6040: Register child device for twl6040-pdmclk Peter Ujfalusi
2016-08-31 11:46   ` Peter Ujfalusi
2016-08-31 14:38   ` Lee Jones
2016-08-31 14:39   ` Lee Jones
2016-09-27  8:14     ` Peter Ujfalusi
2016-09-27  8:14       ` Peter Ujfalusi
2016-09-27 18:50       ` Lee Jones

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.