Linux I2C development
 help / color / mirror / Atom feed
* [PATCH] i2c: uniphier[-f]: fix bool logic calculation
From: Masahiro Yamada @ 2016-10-19  4:38 UTC (permalink / raw)
  To: linux-i2c; +Cc: Masahiro Yamada, linux-arm-kernel, linux-kernel, Wolfram Sang

This code is working, but it should not depend on how "bool" is
typedef'ed, or the bit position of I2C_M_RD.

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
---

 drivers/i2c/busses/i2c-uniphier-f.c | 2 +-
 drivers/i2c/busses/i2c-uniphier.c   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/i2c/busses/i2c-uniphier-f.c b/drivers/i2c/busses/i2c-uniphier-f.c
index db9105e..b54448e 100644
--- a/drivers/i2c/busses/i2c-uniphier-f.c
+++ b/drivers/i2c/busses/i2c-uniphier-f.c
@@ -309,7 +309,7 @@ static int uniphier_fi2c_master_xfer_one(struct i2c_adapter *adap,
 					 struct i2c_msg *msg, bool stop)
 {
 	struct uniphier_fi2c_priv *priv = i2c_get_adapdata(adap);
-	bool is_read = msg->flags & I2C_M_RD;
+	bool is_read = !!(msg->flags & I2C_M_RD);
 	unsigned long time_left;
 
 	dev_dbg(&adap->dev, "%s: addr=0x%02x, len=%d, stop=%d\n",
diff --git a/drivers/i2c/busses/i2c-uniphier.c b/drivers/i2c/busses/i2c-uniphier.c
index 56e92af..cc80bb2 100644
--- a/drivers/i2c/busses/i2c-uniphier.c
+++ b/drivers/i2c/busses/i2c-uniphier.c
@@ -177,7 +177,7 @@ static int uniphier_i2c_stop(struct i2c_adapter *adap)
 static int uniphier_i2c_master_xfer_one(struct i2c_adapter *adap,
 					struct i2c_msg *msg, bool stop)
 {
-	bool is_read = msg->flags & I2C_M_RD;
+	bool is_read = !!(msg->flags & I2C_M_RD);
 	bool recovery = false;
 	int ret;
 
-- 
1.9.1

^ permalink raw reply related

* RE: [v12, 0/8] Fix eSDHC host version register bug
From: Y.B. Lu @ 2016-10-19  2:47 UTC (permalink / raw)
  To: gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org
  Cc: Mark Rutland, Ulf Hansson, X.B. Xie, M.H. Lian,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-clk,
	Qiang Zhao, Russell King, Bhupesh Sharma, Jochen Friedrich,
	Claudiu Manoil,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Arnd Bergmann,
	Scott Wood, Rob Herring, Santosh Shilimkar,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mmc,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Leo Li <le>
In-Reply-To: <CAPDyKFoit0sTPpfi2=AHcdZsDwOJxbBX68O-1jBFL=5JN0m6_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

+ Greg

Hi Greg,

I submitted this patchset for a MMC bug fix, and introduce the below patch which needs your ACK.
> > Arnd Bergmann (1):
> >   base: soc: introduce soc_device_match() interface
https://patchwork.kernel.org/patch/9342913/

Could you help to review it and give some comments or ACK.
Thank you very much.



Best regards,
Yangbo Lu


> -----Original Message-----
> From: Ulf Hansson [mailto:ulf.hansson-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org]
> Sent: Tuesday, October 18, 2016 6:48 PM
> To: Y.B. Lu
> Cc: linux-mmc; Scott Wood; Arnd Bergmann; linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org;
> devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org; linux-
> kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; linux-clk; linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org; netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; Mark Rutland;
> Rob Herring; Russell King; Jochen Friedrich; Joerg Roedel; Claudiu Manoil;
> Bhupesh Sharma; Qiang Zhao; Kumar Gala; Santosh Shilimkar; Leo Li; X.B.
> Xie; M.H. Lian
> Subject: Re: [v12, 0/8] Fix eSDHC host version register bug
> 
> On 21 September 2016 at 08:57, Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org> wrote:
> > This patchset is used to fix a host version register bug in the
> > T4240-R1.0-R2.0 eSDHC controller. To match the SoC version and
> > revision, 10 previous version patchsets had tried many methods but all
> of them were rejected by reviewers.
> > Such as
> >         - dts compatible method
> >         - syscon method
> >         - ifdef PPC method
> >         - GUTS driver getting SVR method Anrd suggested a
> > soc_device_match method in v10, and this is the only available method
> > left now. This v11 patchset introduces the soc_device_match interface
> > in soc driver.
> >
> > The first six patches of Yangbo are to add the GUTS driver. This is
> > used to register a soc device which contain soc version and revision
> information.
> > The other two patches introduce the soc_device_match method in soc
> > driver and apply it on esdhc driver to fix this bug.
> >
> > Arnd Bergmann (1):
> >   base: soc: introduce soc_device_match() interface
> >
> > Yangbo Lu (7):
> >   dt: bindings: update Freescale DCFG compatible
> >   ARM64: dts: ls2080a: add device configuration node
> >   dt: bindings: move guts devicetree doc out of powerpc directory
> >   powerpc/fsl: move mpc85xx.h to include/linux/fsl
> >   soc: fsl: add GUTS driver for QorIQ platforms
> >   MAINTAINERS: add entry for Freescale SoC drivers
> >   mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0
> >
> >  Documentation/devicetree/bindings/arm/fsl.txt      |   6 +-
> >  .../bindings/{powerpc => soc}/fsl/guts.txt         |   3 +
> >  MAINTAINERS                                        |  11 +-
> >  arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi     |   6 +
> >  arch/powerpc/kernel/cpu_setup_fsl_booke.S          |   2 +-
> >  arch/powerpc/sysdev/fsl_pci.c                      |   2 +-
> >  drivers/base/Kconfig                               |   1 +
> >  drivers/base/soc.c                                 |  66 ++++++
> >  drivers/clk/clk-qoriq.c                            |   3 +-
> >  drivers/i2c/busses/i2c-mpc.c                       |   2 +-
> >  drivers/iommu/fsl_pamu.c                           |   3 +-
> >  drivers/mmc/host/Kconfig                           |   1 +
> >  drivers/mmc/host/sdhci-of-esdhc.c                  |  20 ++
> >  drivers/net/ethernet/freescale/gianfar.c           |   2 +-
> >  drivers/soc/Kconfig                                |   2 +-
> >  drivers/soc/fsl/Kconfig                            |  19 ++
> >  drivers/soc/fsl/Makefile                           |   1 +
> >  drivers/soc/fsl/guts.c                             | 257
> +++++++++++++++++++++
> >  include/linux/fsl/guts.h                           | 125 ++++++----
> >  .../asm/mpc85xx.h => include/linux/fsl/svr.h       |   4 +-
> >  include/linux/sys_soc.h                            |   3 +
> >  21 files changed, 478 insertions(+), 61 deletions(-)  rename
> > Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)
> > create mode 100644 drivers/soc/fsl/Kconfig  create mode 100644
> > drivers/soc/fsl/guts.c  rename arch/powerpc/include/asm/mpc85xx.h =>
> > include/linux/fsl/svr.h (97%)
> >
> > --
> > 2.1.0.27.g96db324
> >
> 
> This looks good to me! I am not sure which tree you want this to be
> picked up through, but unless no other volunteers I can take it through
> my mmc tree.
> 
> Although, before considering to apply, I need an ack from Scott/Arnd for
> the guts driver in patch 5/8 and I need an ack from Greg for patch 7/8,
> where the soc_device_match() interface is added (seems like you didn't
> add him on cc/to).
> 
> Kind regards
> Uffe

^ permalink raw reply

* RE: [v12, 0/8] Fix eSDHC host version register bug
From: Y.B. Lu @ 2016-10-19  2:40 UTC (permalink / raw)
  To: Ulf Hansson, Scott Wood, Arnd Bergmann
  Cc: Mark Rutland, X.B. Xie, M.H. Lian,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-clk,
	Qiang Zhao, Russell King, Bhupesh Sharma, Jochen Friedrich,
	Claudiu Manoil,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Rob Herring,
	Santosh Shilimkar,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-mmc,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Leo Li,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	Kumar
In-Reply-To: <CAPDyKFoit0sTPpfi2=AHcdZsDwOJxbBX68O-1jBFL=5JN0m6_w-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>

> -----Original Message-----
> From: Ulf Hansson [mailto:ulf.hansson-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org]
> Sent: Tuesday, October 18, 2016 6:48 PM
> To: Y.B. Lu
> Cc: linux-mmc; Scott Wood; Arnd Bergmann; linuxppc-dev-uLR06cmDAlY/bJ5BZ2RsiQ@public.gmane.org;
> devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org; linux-
> kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; linux-clk; linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org;
> iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org; netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org; Mark Rutland;
> Rob Herring; Russell King; Jochen Friedrich; Joerg Roedel; Claudiu Manoil;
> Bhupesh Sharma; Qiang Zhao; Kumar Gala; Santosh Shilimkar; Leo Li; X.B.
> Xie; M.H. Lian
> Subject: Re: [v12, 0/8] Fix eSDHC host version register bug
> 
> On 21 September 2016 at 08:57, Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org> wrote:
> > This patchset is used to fix a host version register bug in the
> > T4240-R1.0-R2.0 eSDHC controller. To match the SoC version and
> > revision, 10 previous version patchsets had tried many methods but all
> of them were rejected by reviewers.
> > Such as
> >         - dts compatible method
> >         - syscon method
> >         - ifdef PPC method
> >         - GUTS driver getting SVR method Anrd suggested a
> > soc_device_match method in v10, and this is the only available method
> > left now. This v11 patchset introduces the soc_device_match interface
> > in soc driver.
> >
> > The first six patches of Yangbo are to add the GUTS driver. This is
> > used to register a soc device which contain soc version and revision
> information.
> > The other two patches introduce the soc_device_match method in soc
> > driver and apply it on esdhc driver to fix this bug.
> >
> > Arnd Bergmann (1):
> >   base: soc: introduce soc_device_match() interface
> >
> > Yangbo Lu (7):
> >   dt: bindings: update Freescale DCFG compatible
> >   ARM64: dts: ls2080a: add device configuration node
> >   dt: bindings: move guts devicetree doc out of powerpc directory
> >   powerpc/fsl: move mpc85xx.h to include/linux/fsl
> >   soc: fsl: add GUTS driver for QorIQ platforms
> >   MAINTAINERS: add entry for Freescale SoC drivers
> >   mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0
> >
> >  Documentation/devicetree/bindings/arm/fsl.txt      |   6 +-
> >  .../bindings/{powerpc => soc}/fsl/guts.txt         |   3 +
> >  MAINTAINERS                                        |  11 +-
> >  arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi     |   6 +
> >  arch/powerpc/kernel/cpu_setup_fsl_booke.S          |   2 +-
> >  arch/powerpc/sysdev/fsl_pci.c                      |   2 +-
> >  drivers/base/Kconfig                               |   1 +
> >  drivers/base/soc.c                                 |  66 ++++++
> >  drivers/clk/clk-qoriq.c                            |   3 +-
> >  drivers/i2c/busses/i2c-mpc.c                       |   2 +-
> >  drivers/iommu/fsl_pamu.c                           |   3 +-
> >  drivers/mmc/host/Kconfig                           |   1 +
> >  drivers/mmc/host/sdhci-of-esdhc.c                  |  20 ++
> >  drivers/net/ethernet/freescale/gianfar.c           |   2 +-
> >  drivers/soc/Kconfig                                |   2 +-
> >  drivers/soc/fsl/Kconfig                            |  19 ++
> >  drivers/soc/fsl/Makefile                           |   1 +
> >  drivers/soc/fsl/guts.c                             | 257
> +++++++++++++++++++++
> >  include/linux/fsl/guts.h                           | 125 ++++++----
> >  .../asm/mpc85xx.h => include/linux/fsl/svr.h       |   4 +-
> >  include/linux/sys_soc.h                            |   3 +
> >  21 files changed, 478 insertions(+), 61 deletions(-)  rename
> > Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)
> > create mode 100644 drivers/soc/fsl/Kconfig  create mode 100644
> > drivers/soc/fsl/guts.c  rename arch/powerpc/include/asm/mpc85xx.h =>
> > include/linux/fsl/svr.h (97%)
> >
> > --
> > 2.1.0.27.g96db324
> >
> 
> This looks good to me! I am not sure which tree you want this to be
> picked up through, but unless no other volunteers I can take it through
> my mmc tree.
> 
> Although, before considering to apply, I need an ack from Scott/Arnd for
> the guts driver in patch 5/8 and I need an ack from Greg for patch 7/8,
> where the soc_device_match() interface is added (seems like you didn't
> add him on cc/to).
> 

[Lu Yangbo-B47093] Thanks a lot for your clarifying, Uffe.
This patchset was based on mmc tree, and needed your picking up.
But I think it needs to be rebased now since I saw qbman driver was in drivers/soc/fsl/ now.
I will do that after collecting others' ACKs or comments.

Hi Scott and Arnd,
Could I get your ACTs if there're no other changes needed?
Thanks a lot.

> Kind regards
> Uffe

^ permalink raw reply

* [PATCH 4/4] i2c: digicolor: Fix module autoload
From: Javier Martinez Canillas @ 2016-10-18 21:01 UTC (permalink / raw)
  To: linux-kernel
  Cc: Javier Martinez Canillas, Baruch Siach, Wolfram Sang,
	linux-arm-kernel, linux-i2c
In-Reply-To: <1476824508-4679-1-git-send-email-javier@osg.samsung.com>

If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.

Export the module alias information using the MODULE_DEVICE_TABLE() macro.

Before this patch:

$ modinfo drivers/i2c/busses/i2c-digicolor.ko | grep alias
$

After this patch:

$ modinfo drivers/i2c/busses/i2c-digicolor.ko | grep alias
alias:          of:N*T*Ccnxt,cx92755-i2cC*
alias:          of:N*T*Ccnxt,cx92755-i2c

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>

---

 drivers/i2c/busses/i2c-digicolor.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/i2c/busses/i2c-digicolor.c b/drivers/i2c/busses/i2c-digicolor.c
index 9604024e0eb0..49f2084f7bb5 100644
--- a/drivers/i2c/busses/i2c-digicolor.c
+++ b/drivers/i2c/busses/i2c-digicolor.c
@@ -368,6 +368,7 @@ static const struct of_device_id dc_i2c_match[] = {
 	{ .compatible = "cnxt,cx92755-i2c" },
 	{ },
 };
+MODULE_DEVICE_TABLE(of, dc_i2c_match);
 
 static struct platform_driver dc_i2c_driver = {
 	.probe   = dc_i2c_probe,
-- 
2.7.4

^ permalink raw reply related

* [PATCH 3/4] i2c: xlr: Fix module autoload for OF registration
From: Javier Martinez Canillas @ 2016-10-18 21:01 UTC (permalink / raw)
  To: linux-kernel; +Cc: Javier Martinez Canillas, Wolfram Sang, linux-i2c
In-Reply-To: <1476824508-4679-1-git-send-email-javier@osg.samsung.com>

If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.

Export the module alias information using the MODULE_DEVICE_TABLE() macro.

Before this patch:

$ modinfo drivers/i2c/busses/i2c-xlr.ko | grep alias
alias:          platform:xlr-i2cbus

After this patch:

$ modinfo drivers/i2c/busses/i2c-xlr.ko | grep alias
alias:          platform:xlr-i2cbus
alias:          of:N*T*Csigma,smp8642-i2cC*
alias:          of:N*T*Csigma,smp8642-i2c

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
---

 drivers/i2c/busses/i2c-xlr.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/i2c/busses/i2c-xlr.c b/drivers/i2c/busses/i2c-xlr.c
index 0968f59b6df5..ad17d88d8573 100644
--- a/drivers/i2c/busses/i2c-xlr.c
+++ b/drivers/i2c/busses/i2c-xlr.c
@@ -358,6 +358,7 @@ static const struct of_device_id xlr_i2c_dt_ids[] = {
 	},
 	{ }
 };
+MODULE_DEVICE_TABLE(of, xlr_i2c_dt_ids);
 
 static int xlr_i2c_probe(struct platform_device *pdev)
 {
-- 
2.7.4

^ permalink raw reply related

* [PATCH 2/4] i2c: xlp9xx: Fix module autoload
From: Javier Martinez Canillas @ 2016-10-18 21:01 UTC (permalink / raw)
  To: linux-kernel; +Cc: Javier Martinez Canillas, Wolfram Sang, linux-i2c
In-Reply-To: <1476824508-4679-1-git-send-email-javier@osg.samsung.com>

If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.

Export the module alias information using the MODULE_DEVICE_TABLE() macro.

Before this patch:

$ modinfo drivers/i2c/busses/i2c-xlp9xx.ko | grep alias
$

After this patch:

$ modinfo drivers/i2c/busses/i2c-xlp9xx.ko | grep alias
alias:          of:N*T*Cnetlogic,xlp980-i2cC*
alias:          of:N*T*Cnetlogic,xlp980-i2c

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
---

 drivers/i2c/busses/i2c-xlp9xx.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/i2c/busses/i2c-xlp9xx.c b/drivers/i2c/busses/i2c-xlp9xx.c
index 2a972ed7aa0d..e29ff37a43bd 100644
--- a/drivers/i2c/busses/i2c-xlp9xx.c
+++ b/drivers/i2c/busses/i2c-xlp9xx.c
@@ -426,6 +426,7 @@ static const struct of_device_id xlp9xx_i2c_of_match[] = {
 	{ .compatible = "netlogic,xlp980-i2c", },
 	{ /* sentinel */ },
 };
+MODULE_DEVICE_TABLE(of, xlp9xx_i2c_of_match);
 
 #ifdef CONFIG_ACPI
 static const struct acpi_device_id xlp9xx_i2c_acpi_ids[] = {
-- 
2.7.4

^ permalink raw reply related

* [PATCH 1/4] i2c: jz4780: Fix module autoload
From: Javier Martinez Canillas @ 2016-10-18 21:01 UTC (permalink / raw)
  To: linux-kernel; +Cc: Javier Martinez Canillas, Wolfram Sang, linux-i2c
In-Reply-To: <1476824508-4679-1-git-send-email-javier@osg.samsung.com>

If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.

Export the module alias information using the MODULE_DEVICE_TABLE() macro.

Before this patch:

$ modinfo drivers/i2c/busses/i2c-jz4780.ko | grep alias
$

After this patch:

$ modinfo drivers/i2c/busses/i2c-jz4780.ko | grep alias
alias:          of:N*T*Cingenic,jz4780-i2cC*
alias:          of:N*T*Cingenic,jz4780-i2c

Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
---

 drivers/i2c/busses/i2c-jz4780.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/i2c/busses/i2c-jz4780.c b/drivers/i2c/busses/i2c-jz4780.c
index b8ea62105f42..30132c3957cd 100644
--- a/drivers/i2c/busses/i2c-jz4780.c
+++ b/drivers/i2c/busses/i2c-jz4780.c
@@ -729,6 +729,7 @@ static const struct of_device_id jz4780_i2c_of_matches[] = {
 	{ .compatible = "ingenic,jz4780-i2c", },
 	{ /* sentinel */ }
 };
+MODULE_DEVICE_TABLE(of, jz4780_i2c_of_matches);
 
 static int jz4780_i2c_probe(struct platform_device *pdev)
 {
-- 
2.7.4

^ permalink raw reply related

* [PATCH 0/4] i2c: Fix module autoload for some i2c busses platform drivers
From: Javier Martinez Canillas @ 2016-10-18 21:01 UTC (permalink / raw)
  To: linux-kernel
  Cc: Javier Martinez Canillas, Baruch Siach, Wolfram Sang,
	linux-arm-kernel, linux-i2c

Hello Wolfram,

I noticed that module autoload won't be working in some of the i2c
busses drivers. This patch series contains the fixes for these.

Best regards,
Javier


Javier Martinez Canillas (4):
  i2c: jz4780: Fix module autoload
  i2c: xlp9xx: Fix module autoload
  i2c: xlr: Fix module autoload for OF registration
  i2c: digicolor: Fix module autoload

 drivers/i2c/busses/i2c-digicolor.c | 1 +
 drivers/i2c/busses/i2c-jz4780.c    | 1 +
 drivers/i2c/busses/i2c-xlp9xx.c    | 1 +
 drivers/i2c/busses/i2c-xlr.c       | 1 +
 4 files changed, 4 insertions(+)

-- 
2.7.4

^ permalink raw reply

* Re: [PATCH v2 3/4] Device bindings documentation updated ACPI-enabled platforms not currently supported
From: Wolfram Sang @ 2016-10-18 15:17 UTC (permalink / raw)
  To: Ramiro Oliveira
  Cc: Mark Rutland, Luis.Oliveira, jarkko.nikula, andriy.shevchenko,
	mika.westerberg, linux-i2c, linux-kernel, robh+dt, devicetree,
	CARLOS.PALMINHA
In-Reply-To: <55cc91af-8d24-8aea-f74f-2ef40cd8ea5a@synopsys.com>

[-- Attachment #1: Type: text/plain, Size: 406 bytes --]


> This is needed because the configuration is different and the i2c-designware
> cannot be master/slave without a reset. To resolve that I added this property
> to bind it as a slave when needed.

Aww, pity that the HW can't do that. Do you have details why?

If that is really a HW limitation, then I'd suggest having a seperate
driver for slave-only mode so we can differentiate by compatible
strings.


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply

* Re: [PATCH v2 3/4] Device bindings documentation updated ACPI-enabled platforms not currently supported
From: Ramiro Oliveira @ 2016-10-18 14:50 UTC (permalink / raw)
  To: Mark Rutland, Luis.Oliveira
  Cc: jarkko.nikula, andriy.shevchenko, mika.westerberg, wsa, linux-i2c,
	linux-kernel, robh+dt, devicetree, CARLOS.PALMINHA,
	Ramiro.Oliveira
In-Reply-To: <20161014173014.GA26269@leverpostej>

On 10/14/2016 6:30 PM, Mark Rutland wrote:
> On Fri, Oct 14, 2016 at 05:52:50PM +0100, Luis.Oliveira@synopsys.com wrote:
>> -		is_slave = device_property_read_bool(&pdev->dev, "isslave");
> Which tree is this based on? I cant see the existing isslave property in
> mainline HEAD (commit 29fbff8698fc0ac1).

I'm replying for Luís, since at the moment he's not able to reply.

This is a custom property since this I2C core doesn't support both master and
slave at the same time.

>
>> +#ifndef CONFIG_ACPI
>> +		is_slave = device_property_read_bool(&pdev->dev, "is-slave");
>> +#endif
> This ifdef is broken. At least for arm64, a single kernel image can be
> booted with either ACPI or DT. We need separate accessors for DT and
> ACPI to handle these differently, or you need to explicitly check
> whether or not you have ACPI or DT at runtime.

Thanks for the feedback, I'll take a look at this

>
> Thanks,
> Mark.

Thanks,
Ramiro

^ permalink raw reply

* Re: [PATCH v2 3/4] Device bindings documentation updated ACPI-enabled platforms not currently supported
From: Rob Herring @ 2016-10-18 14:33 UTC (permalink / raw)
  To: Luis.Oliveira
  Cc: jarkko.nikula, andriy.shevchenko, mika.westerberg, wsa, linux-i2c,
	linux-kernel, mark.rutland, devicetree, CARLOS.PALMINHA,
	Ramiro.Oliveira
In-Reply-To: <36f4b1736e36b039af15b13645df0de492f1b6e1.1476462204.git.lolivei@synopsys.com>

On Fri, Oct 14, 2016 at 05:52:50PM +0100, Luis.Oliveira@synopsys.com wrote:
> From: Luis Oliveira <lolivei@synopsys.com>
> 
> Signed-off-by: Luis Oliveira <lolivei@synopsys.com>
> ---
>  Documentation/devicetree/bindings/i2c/i2c-designware.txt | 5 ++++-
>  drivers/i2c/busses/i2c-designware-platdrv.c              | 4 +++-
>  2 files changed, 7 insertions(+), 2 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/i2c/i2c-designware.txt b/Documentation/devicetree/bindings/i2c/i2c-designware.txt
> index fee26dc..d3d163c 100644
> --- a/Documentation/devicetree/bindings/i2c/i2c-designware.txt
> +++ b/Documentation/devicetree/bindings/i2c/i2c-designware.txt
> @@ -19,6 +19,8 @@ Optional properties :
>  
>   - i2c-sda-falling-time-ns : should contain the SDA falling time in nanoseconds.
>     This value which is by default 300ns is used to compute the tHIGH period.
> +   
> + - is-slave : indicates if the block is a I2C slave device.

This should be documented as a generic property.

>  
>  Example :
>  
> @@ -30,7 +32,7 @@ Example :
>  		interrupts = <11>;
>  		clock-frequency = <400000>;
>  	};
> -
> +	

Adding trailing whitespace...

>  	i2c@1120000 {
>  		#address-cells = <1>;
>  		#size-cells = <0>;
> @@ -42,4 +44,5 @@ Example :
>  		i2c-sda-hold-time-ns = <300>;
>  		i2c-sda-falling-time-ns = <300>;
>  		i2c-scl-falling-time-ns = <300>;
> +		is-slave;
>  	};

^ permalink raw reply

* Re: [v12, 0/8] Fix eSDHC host version register bug
From: Ulf Hansson @ 2016-10-18 10:47 UTC (permalink / raw)
  To: Yangbo Lu
  Cc: Mark Rutland, Xiaobo Xie, Minghuan Lian,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-clk,
	Qiang Zhao, Russell King, Bhupesh Sharma, Jochen Friedrich,
	Claudiu Manoil,
	devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Arnd Bergmann,
	Scott Wood, Rob Herring, Santosh Shilimkar,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA, linux-mmc,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Leo Li,
	iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA, Kumar
In-Reply-To: <1474441040-11946-1-git-send-email-yangbo.lu-3arQi8VN3Tc@public.gmane.org>

On 21 September 2016 at 08:57, Yangbo Lu <yangbo.lu-3arQi8VN3Tc@public.gmane.org> wrote:
> This patchset is used to fix a host version register bug in the T4240-R1.0-R2.0
> eSDHC controller. To match the SoC version and revision, 10 previous version
> patchsets had tried many methods but all of them were rejected by reviewers.
> Such as
>         - dts compatible method
>         - syscon method
>         - ifdef PPC method
>         - GUTS driver getting SVR method
> Anrd suggested a soc_device_match method in v10, and this is the only available
> method left now. This v11 patchset introduces the soc_device_match interface in
> soc driver.
>
> The first six patches of Yangbo are to add the GUTS driver. This is used to
> register a soc device which contain soc version and revision information.
> The other two patches introduce the soc_device_match method in soc driver
> and apply it on esdhc driver to fix this bug.
>
> Arnd Bergmann (1):
>   base: soc: introduce soc_device_match() interface
>
> Yangbo Lu (7):
>   dt: bindings: update Freescale DCFG compatible
>   ARM64: dts: ls2080a: add device configuration node
>   dt: bindings: move guts devicetree doc out of powerpc directory
>   powerpc/fsl: move mpc85xx.h to include/linux/fsl
>   soc: fsl: add GUTS driver for QorIQ platforms
>   MAINTAINERS: add entry for Freescale SoC drivers
>   mmc: sdhci-of-esdhc: fix host version for T4240-R1.0-R2.0
>
>  Documentation/devicetree/bindings/arm/fsl.txt      |   6 +-
>  .../bindings/{powerpc => soc}/fsl/guts.txt         |   3 +
>  MAINTAINERS                                        |  11 +-
>  arch/arm64/boot/dts/freescale/fsl-ls2080a.dtsi     |   6 +
>  arch/powerpc/kernel/cpu_setup_fsl_booke.S          |   2 +-
>  arch/powerpc/sysdev/fsl_pci.c                      |   2 +-
>  drivers/base/Kconfig                               |   1 +
>  drivers/base/soc.c                                 |  66 ++++++
>  drivers/clk/clk-qoriq.c                            |   3 +-
>  drivers/i2c/busses/i2c-mpc.c                       |   2 +-
>  drivers/iommu/fsl_pamu.c                           |   3 +-
>  drivers/mmc/host/Kconfig                           |   1 +
>  drivers/mmc/host/sdhci-of-esdhc.c                  |  20 ++
>  drivers/net/ethernet/freescale/gianfar.c           |   2 +-
>  drivers/soc/Kconfig                                |   2 +-
>  drivers/soc/fsl/Kconfig                            |  19 ++
>  drivers/soc/fsl/Makefile                           |   1 +
>  drivers/soc/fsl/guts.c                             | 257 +++++++++++++++++++++
>  include/linux/fsl/guts.h                           | 125 ++++++----
>  .../asm/mpc85xx.h => include/linux/fsl/svr.h       |   4 +-
>  include/linux/sys_soc.h                            |   3 +
>  21 files changed, 478 insertions(+), 61 deletions(-)
>  rename Documentation/devicetree/bindings/{powerpc => soc}/fsl/guts.txt (91%)
>  create mode 100644 drivers/soc/fsl/Kconfig
>  create mode 100644 drivers/soc/fsl/guts.c
>  rename arch/powerpc/include/asm/mpc85xx.h => include/linux/fsl/svr.h (97%)
>
> --
> 2.1.0.27.g96db324
>

This looks good to me! I am not sure which tree you want this to be
picked up through, but unless no other volunteers I can take it
through my mmc tree.

Although, before considering to apply, I need an ack from Scott/Arnd
for the guts driver in patch 5/8 and I need an ack from Greg for patch
7/8, where the soc_device_match() interface is added (seems like you
didn't add him on cc/to).

Kind regards
Uffe

^ permalink raw reply

* Re: [PATCH] mfd: axp20x-i2c: Add i2c-ids to fix module auto-loading
From: Hans de Goede @ 2016-10-18 10:25 UTC (permalink / raw)
  To: Chen-Yu Tsai
  Cc: Lee Jones, Sebastian Reichel, Dennis Gilmore, Maxime Ripard,
	open list:THERMAL, linux-arm-kernel, Wolfram Sang, linux-i2c
In-Reply-To: <CAGb2v67iQikSHcwS15VmSC6fNMVG9Zya9fz6C6b5+wW43rPZfw@mail.gmail.com>

Hi,

On 18-10-16 07:25, Chen-Yu Tsai wrote:
> On Wed, Oct 5, 2016 at 11:51 PM, Hans de Goede <hdegoede@redhat.com> wrote:
>> The i2c subsys does not load modules by compatible, only by
>> i2c-id, with e.g. a modalias of: "i2c:axp209".
>>
>> Populate the axp20x_i2c_id[] table with supported ids, so that
>> module auto-loading will work.
>>
>> Reported-by: Dennis Gilmore <dennis@ausil.us>
>> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
>
> Acked-by: Chen-Yu Tsai <wens@csie.org>
>
> Even though axp20x-i2c seems to be the only "DT only" i2c client,
> would it make sense to add DT-based module autoloading to the i2c
> core?

If it is not too invasive, then yes that would be a sensible addition IMHO.

Regards,

Hans

^ permalink raw reply

* Re: [PATCH] mfd: axp20x-i2c: Add i2c-ids to fix module auto-loading
From: Chen-Yu Tsai @ 2016-10-18  5:25 UTC (permalink / raw)
  To: Hans de Goede
  Cc: Lee Jones, Sebastian Reichel, Dennis Gilmore, Maxime Ripard,
	Chen-Yu Tsai, open list:THERMAL, linux-arm-kernel, Wolfram Sang,
	linux-i2c
In-Reply-To: <20161005155112.13774-2-hdegoede@redhat.com>

On Wed, Oct 5, 2016 at 11:51 PM, Hans de Goede <hdegoede@redhat.com> wrote:
> The i2c subsys does not load modules by compatible, only by
> i2c-id, with e.g. a modalias of: "i2c:axp209".
>
> Populate the axp20x_i2c_id[] table with supported ids, so that
> module auto-loading will work.
>
> Reported-by: Dennis Gilmore <dennis@ausil.us>
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Acked-by: Chen-Yu Tsai <wens@csie.org>

Even though axp20x-i2c seems to be the only "DT only" i2c client,
would it make sense to add DT-based module autoloading to the i2c
core?

This also made me realize we probably don't have module auto-loading
for sunxi-rsb either.

Both should be doable with Stephen Boyd's "of: device: Export
of_device_{get_modalias, uvent_modalias} to modules" patch.

Regards
ChenYu

^ permalink raw reply

* Re: [PATCH] spi: mark device nodes only in case of successful instantiation
From: Wolfram Sang @ 2016-10-17 21:09 UTC (permalink / raw)
  To: Pantelis Antoniou
  Cc: Ralf Ramsauer, Geert Uytterhoeven, Mark Brown, linux-spi,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Geert Uytterhoeven, Linux I2C
In-Reply-To: <20161017210752.GA1681@katana>

[-- Attachment #1: Type: text/plain, Size: 198 bytes --]

> > Thanks for this. This is a very rare case that’s easy to slip through.
> > It is good to be consistent :)
> 
> I read this as acked-by for the series?

Ah, I mixed up. You acked V2 :)


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply

* Re: [PATCH] spi: mark device nodes only in case of successful instantiation
From: Wolfram Sang @ 2016-10-17 21:07 UTC (permalink / raw)
  To: Pantelis Antoniou
  Cc: Ralf Ramsauer, Geert Uytterhoeven, Mark Brown, linux-spi,
	linux-kernel@vger.kernel.org, Geert Uytterhoeven, Linux I2C
In-Reply-To: <33118B65-9BF4-45AF-AC55-B44BECB5BBD1@gmail.com>

[-- Attachment #1: Type: text/plain, Size: 3254 bytes --]

On Mon, Oct 17, 2016 at 10:20:47PM +0300, Pantelis Antoniou wrote:
> Hi Ralf,
> 
> > On Oct 16, 2016, at 12:55 , Ralf Ramsauer <ralf@ramses-pyramidenbau.de> wrote:
> > 
> > Hi Geert,
> > 
> > On 10/16/2016 10:49 AM, Geert Uytterhoeven wrote:
> >> Hi Ralf,
> >> 
> >> (Cc i2c)
> >> 
> >> On Fri, Oct 14, 2016 at 9:31 PM, Ralf Ramsauer
> >> <ralf@ramses-pyramidenbau.de> wrote:
> >>> Instantiated SPI device nodes are marked with OF_POPULATE. This was
> >>> introduced in bd6c164. On unloading, loaded device nodes will of course
> >>> be unmarked. The problem are nodes the fail during initialisation: If a
> >>> node failed during registration, it won't be unloaded and hence never be
> >>> unmarked again.
> >>> 
> >>> So if a SPI driver module is unloaded and reloaded, it will skip nodes
> >>> that failed before.
> >>> 
> >>> Skip device nodes that are already populated and mark them only in case
> >>> of success.
> >>> 
> >>> Fixes: bd6c164 ("spi: Mark instantiated device nodes with OF_POPULATE")
> >>> Signed-off-by: Ralf Ramsauer <ralf@ramses-pyramidenbau.de>
> >>> Cc: Geert Uytterhoeven <geert+renesas@glider.be>
> >>> ---
> >>> Hi,
> >>> 
> >>> imagine the following situation: you loaded a spi driver as module, but
> >>> it fails to instantiate, because of some reasons (e.g. some resources,
> >>> like gpios, might be in use in userspace).
> >>> 
> >>> When reloading the driver, _all_ nodes, including previously failed
> >>> ones, should be probed again. This is not the case at the moment.
> >>> Current behaviour only re-registers nodes that were previously
> >>> successfully loaded.
> >>> 
> >>> This small patches fixes this behaviour. I stumbled over this while
> >>> working on a spi driver.
> >> 
> >> Thanks for your patch!
> >> 
> >>> drivers/spi/spi.c | 7 +++++--
> >>> 1 file changed, 5 insertions(+), 2 deletions(-)
> >>> 
> >>> diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
> >>> index 200ca22..f96a04e 100644
> >>> --- a/drivers/spi/spi.c
> >>> +++ b/drivers/spi/spi.c
> >>> @@ -1604,12 +1604,15 @@ static void of_register_spi_devices(struct spi_master *master)
> >>>                return;
> >>> 
> >>>        for_each_available_child_of_node(master->dev.of_node, nc) {
> >>> -               if (of_node_test_and_set_flag(nc, OF_POPULATED))
> >>> +               if (of_node_check_flag(nc, OF_POPULATED))
> >>>                        continue;
> >>>                spi = of_register_spi_device(master, nc);
> >>> -               if (IS_ERR(spi))
> >>> +               if (IS_ERR(spi)) {
> >>>                        dev_warn(&master->dev, "Failed to create SPI device for %s\n",
> >>>                                nc->full_name);
> >>> +                       continue;
> >>> +               }
> >>> +               of_node_set_flag(nc, OF_POPULATED);
> >> 
> >> I think it's safer to keep the atomic test-and-set, but clear the flag on
> >> failure, cfr. of_platform_device_create_pdata() and of_amba_device_create().
> > Ack, no prob. Let me change this in the next version.
> >> 

> Thanks for this. This is a very rare case that’s easy to slip through.
> It is good to be consistent :)

I read this as acked-by for the series?


[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply

* Re: [PATCH] spi: mark device nodes only in case of successful instantiation
From: Pantelis Antoniou @ 2016-10-17 19:20 UTC (permalink / raw)
  To: Ralf Ramsauer
  Cc: Geert Uytterhoeven, Mark Brown, linux-spi,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	Geert Uytterhoeven, Wolfram Sang, Linux I2C
In-Reply-To: <39e8d53a-a93d-feeb-044f-9b1b239dff21-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org>

Hi Ralf,

> On Oct 16, 2016, at 12:55 , Ralf Ramsauer <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org> wrote:
> 
> Hi Geert,
> 
> On 10/16/2016 10:49 AM, Geert Uytterhoeven wrote:
>> Hi Ralf,
>> 
>> (Cc i2c)
>> 
>> On Fri, Oct 14, 2016 at 9:31 PM, Ralf Ramsauer
>> <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org> wrote:
>>> Instantiated SPI device nodes are marked with OF_POPULATE. This was
>>> introduced in bd6c164. On unloading, loaded device nodes will of course
>>> be unmarked. The problem are nodes the fail during initialisation: If a
>>> node failed during registration, it won't be unloaded and hence never be
>>> unmarked again.
>>> 
>>> So if a SPI driver module is unloaded and reloaded, it will skip nodes
>>> that failed before.
>>> 
>>> Skip device nodes that are already populated and mark them only in case
>>> of success.
>>> 
>>> Fixes: bd6c164 ("spi: Mark instantiated device nodes with OF_POPULATE")
>>> Signed-off-by: Ralf Ramsauer <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org>
>>> Cc: Geert Uytterhoeven <geert+renesas-gXvu3+zWzMSzQB+pC5nmwQ@public.gmane.org>
>>> ---
>>> Hi,
>>> 
>>> imagine the following situation: you loaded a spi driver as module, but
>>> it fails to instantiate, because of some reasons (e.g. some resources,
>>> like gpios, might be in use in userspace).
>>> 
>>> When reloading the driver, _all_ nodes, including previously failed
>>> ones, should be probed again. This is not the case at the moment.
>>> Current behaviour only re-registers nodes that were previously
>>> successfully loaded.
>>> 
>>> This small patches fixes this behaviour. I stumbled over this while
>>> working on a spi driver.
>> 
>> Thanks for your patch!
>> 
>>> drivers/spi/spi.c | 7 +++++--
>>> 1 file changed, 5 insertions(+), 2 deletions(-)
>>> 
>>> diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
>>> index 200ca22..f96a04e 100644
>>> --- a/drivers/spi/spi.c
>>> +++ b/drivers/spi/spi.c
>>> @@ -1604,12 +1604,15 @@ static void of_register_spi_devices(struct spi_master *master)
>>>                return;
>>> 
>>>        for_each_available_child_of_node(master->dev.of_node, nc) {
>>> -               if (of_node_test_and_set_flag(nc, OF_POPULATED))
>>> +               if (of_node_check_flag(nc, OF_POPULATED))
>>>                        continue;
>>>                spi = of_register_spi_device(master, nc);
>>> -               if (IS_ERR(spi))
>>> +               if (IS_ERR(spi)) {
>>>                        dev_warn(&master->dev, "Failed to create SPI device for %s\n",
>>>                                nc->full_name);
>>> +                       continue;
>>> +               }
>>> +               of_node_set_flag(nc, OF_POPULATED);
>> 
>> I think it's safer to keep the atomic test-and-set, but clear the flag on
>> failure, cfr. of_platform_device_create_pdata() and of_amba_device_create().
> Ack, no prob. Let me change this in the next version.
>> 
>> Shouldn't of_spi_notify() be fixed, too?
> Right, that's almost the same path.
>> 
>> The same issue exists for i2c in of_i2c_register_devices() and of_i2c_notify(),
>> which is what I had used as an example.
> Good old c&p ;-)
> I'll fix and test that tomorrow and come back with two patches, as it
> touches different subsystems.
> 

Thanks for this. This is a very rare case that’s easy to slip through.
It is good to be consistent :)

> Best
>  Ralf
>> 

Regards

— Pantelis

>> Gr{oetje,eeting}s,
>> 
>>                        Geert
>> 
>> --
>> Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert-Td1EMuHUCqxL1ZNQvxDV9g@public.gmane.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
>> 
> 
> 
> -- 
> Ralf Ramsauer
> GPG: 0x8F10049B

--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply

* Re: [PATCH v2 2/2] i2c: mark device nodes only in case of successful instantiation
From: Pantelis Antoniou @ 2016-10-17 19:16 UTC (permalink / raw)
  To: Ralf Ramsauer
  Cc: Mark Brown, Geert Uytterhoeven, Wolfram Sang, Linux SPI,
	Linux I2C, linux-kernel @ vger . kernel . org
In-Reply-To: <20161017135957.20297-3-ralf@ramses-pyramidenbau.de>

Hi Ralf,

> On Oct 17, 2016, at 16:59 , Ralf Ramsauer <ralf@ramses-pyramidenbau.de> wrote:
> 
> Instantiated I2C device nodes are marked with OF_POPULATE. This was
> introduced in 4f001fd. On unloading, loaded device nodes will of course
> be unmarked. The problem are nodes that fail during initialisation: If a
> node fails, it won't be unloaded and hence not be unmarked.
> 
> If a I2C driver module is unloaded and reloaded, it will skip nodes that
> failed before.
> 
> Skip device nodes that are already populated and mark them only in case
> of success.
> 
> Note that the same issue exists for SPI.
> 
> Fixes: 4f001fd ("i2c: Mark instantiated device nodes with OF_POPULATE")
> Signed-off-by: Ralf Ramsauer <ralf@ramses-pyramidenbau.de>
> ---
> drivers/i2c/i2c-core.c | 11 ++++++++++-
> 1 file changed, 10 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
> index 5ab6721..1704fc8 100644
> --- a/drivers/i2c/i2c-core.c
> +++ b/drivers/i2c/i2c-core.c
> @@ -1681,6 +1681,7 @@ static struct i2c_client *of_i2c_register_device(struct i2c_adapter *adap,
> static void of_i2c_register_devices(struct i2c_adapter *adap)
> {
> 	struct device_node *bus, *node;
> +	struct i2c_client *client;
> 
> 	/* Only register child devices if the adapter has a node pointer set */
> 	if (!adap->dev.of_node)
> @@ -1695,7 +1696,14 @@ static void of_i2c_register_devices(struct i2c_adapter *adap)
> 	for_each_available_child_of_node(bus, node) {
> 		if (of_node_test_and_set_flag(node, OF_POPULATED))
> 			continue;
> -		of_i2c_register_device(adap, node);
> +
> +		client = of_i2c_register_device(adap, node);
> +		if (IS_ERR(client)) {
> +			dev_warn(&adap->dev,
> +				 "Failed to create I2C device for %s\n",
> +				 node->full_name);
> +			of_node_clear_flag(node, OF_POPULATED);
> +		}
> 	}
> 
> 	of_node_put(bus);
> @@ -2299,6 +2307,7 @@ static int of_i2c_notify(struct notifier_block *nb, unsigned long action,
> 		if (IS_ERR(client)) {
> 			dev_err(&adap->dev, "failed to create client for '%s'\n",
> 				 rd->dn->full_name);
> +			of_node_clear_flag(rd->dn, OF_POPULATED);
> 			return notifier_from_errno(PTR_ERR(client));
> 		}
> 		break;
> -- 
> 2.10.1
> 

Thanks for this

Acked-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>

^ permalink raw reply

* Re: [PATCH v2 1/2] spi: mark device nodes only in case of successful instantiation
From: Pantelis Antoniou @ 2016-10-17 19:16 UTC (permalink / raw)
  To: Ralf Ramsauer
  Cc: Mark Brown, Geert Uytterhoeven, Wolfram Sang, Linux SPI,
	Linux I2C, linux-kernel @ vger . kernel . org
In-Reply-To: <20161017135957.20297-2-ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org>

Hi Ralf,

> On Oct 17, 2016, at 16:59 , Ralf Ramsauer <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org> wrote:
> 
> Instantiated SPI device nodes are marked with OF_POPULATE. This was
> introduced in bd6c164. On unloading, loaded device nodes will of course
> be unmarked. The problem are nodes that fail during initialisation: If a
> node fails, it won't be unloaded and hence not be unmarked.
> 
> If a SPI driver module is unloaded and reloaded, it will skip nodes that
> failed before.
> 
> Skip device nodes that are already populated and mark them only in case
> of success.
> 
> Note that the same issue exists for I2C.
> 
> Fixes: bd6c164 ("spi: Mark instantiated device nodes with OF_POPULATE")
> Signed-off-by: Ralf Ramsauer <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org>
> ---
> drivers/spi/spi.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
> index 5787b72..838783c 100644
> --- a/drivers/spi/spi.c
> +++ b/drivers/spi/spi.c
> @@ -1618,9 +1618,11 @@ static void of_register_spi_devices(struct spi_master *master)
> 		if (of_node_test_and_set_flag(nc, OF_POPULATED))
> 			continue;
> 		spi = of_register_spi_device(master, nc);
> -		if (IS_ERR(spi))
> +		if (IS_ERR(spi)) {
> 			dev_warn(&master->dev, "Failed to create SPI device for %s\n",
> 				nc->full_name);
> +			of_node_clear_flag(nc, OF_POPULATED);
> +		}
> 	}
> }
> #else
> @@ -3131,6 +3133,7 @@ static int of_spi_notify(struct notifier_block *nb, unsigned long action,
> 		if (IS_ERR(spi)) {
> 			pr_err("%s: failed to create for '%s'\n",
> 					__func__, rd->dn->full_name);
> +			of_node_clear_flag(rd->dn, OF_POPULATED);
> 			return notifier_from_errno(PTR_ERR(spi));
> 		}
> 		break;
> -- 
> 2.10.1
> 

Thanks for this.

Acked-by: Pantelis Antoniou <pantelis.antoniou-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>


--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply

* Re: [PATCH v2 0/2] spi, i2c: mark device nodes only in case of successful instantiation
From: Pantelis Antoniou @ 2016-10-17 19:15 UTC (permalink / raw)
  To: Ralf Ramsauer
  Cc: Mark Brown, Geert Uytterhoeven, Wolfram Sang, Linux SPI,
	Linux I2C, linux-kernel @ vger . kernel . org
In-Reply-To: <20161017135957.20297-1-ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org>

Hi Ralf,

> On Oct 17, 2016, at 16:59 , Ralf Ramsauer <ralf-ex4EvEgDZR1o7HI0AxOeTKwczVv4G7md@public.gmane.org> wrote:
> 
> Hi,
> 
> this one fixes initialisation of I2C/SPI nodes.  Upon failure during
> intialisation, nodes were erroneously populated and never unmarked.
> 
> This lead to the problem that re-loaded drivers will never probe those devices
> again and can easily be fixed by clearing the OF_POPULATE flag when the node
> doesn't successfully initialise.
> 
> For the discussion of v1, see
> https://lkml.org/lkml/2016/10/14/483
> 
>  Ralf
> 
> changes since v1:
>  - also fix I2C core driver
>  - keep the atomic test-and-set, as Geert suggested
> 
> Ralf Ramsauer (2):
>  spi: mark device nodes only in case of successful instantiation
>  i2c: mark device nodes only in case of successful instantiation
> 
> drivers/i2c/i2c-core.c | 11 ++++++++++-
> drivers/spi/spi.c      |  5 ++++-
> 2 files changed, 14 insertions(+), 2 deletions(-)
> 
> -- 
> 2.10.1
> 

Thanks for catching this.

Acked-by: Pantelis Antoniou <pantelis.antoniou-OWPKS81ov/FWk0Htik3J/w@public.gmane.org>


--
To unsubscribe from this list: send the line "unsubscribe linux-spi" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply

* Re: [PATCH 10/10] hwmon: i2cs-fan: Add hwmon dts binding documentation
From: Pantelis Antoniou @ 2016-10-17 19:12 UTC (permalink / raw)
  To: Rob Herring
  Cc: Lee Jones, Linus Walleij, Alexandre Courbot, Mark Rutland,
	Frank Rowand, Wolfram Sang, Richard Purdie, Jacek Anaszewski,
	Jean Delvare, Peter Rosin, Avirup Banerjee, Georgi Vlaev,
	Guenter Roeck, JawaharBalaji Thirumalaisamy, devicetree,
	linux-kernel, linux-gpio, linux-i2c, linux-leds, linux-hwmon
In-Reply-To: <20161010202903.GA9122@rob-hp-laptop>


> On Oct 10, 2016, at 23:29 , Rob Herring <robh@kernel.org> wrote:
> 
> On Fri, Oct 07, 2016 at 06:21:09PM +0300, Pantelis Antoniou wrote:
>> From: Georgi Vlaev <gvlaev@juniper.net>
>> 
>> Adds the I2CS Fan Tray hwmon device tree node documentation.
>> 
>> Signed-off-by: Georgi Vlaev <gvlaev@juniper.net>
>> [Ported from Juniper kernel]
>> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
>> ---
>> Documentation/devicetree/bindings/hwmon/i2cs-fan.txt | 19 +++++++++++++++++++
>> 1 file changed, 19 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/hwmon/i2cs-fan.txt
>> 
>> diff --git a/Documentation/devicetree/bindings/hwmon/i2cs-fan.txt b/Documentation/devicetree/bindings/hwmon/i2cs-fan.txt
>> new file mode 100644
>> index 0000000..4ef880c
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/hwmon/i2cs-fan.txt
>> @@ -0,0 +1,19 @@
>> +Hwmon driver for Juniper fan trays on I2CS Slave FPGA
> 
> This is a h/w description, not a driver.
> 
>> +
>> +Required properties:
>> +
>> +- compatible: "i2cs-fan-hwmon"
> 
> I doubt any fan control h/w has "hwmon" in the name.
> 
>> +
>> +Optional properties:
>> +
>> +- num-fans: fans per tray (default 14)
>> +
>> +- tach-factor: TACH count scaling factor (default 120)
> 
> vendor prefixes needed.
> 
>> +
>> +Example:
>> +
>> +fan-hwmon {
>> +	compatible = "jnx,i2cs-fan-hwmon";
>> +	num-fans = <6>;
>> +	tach-factor = <33>;
>> +};
>> -- 
>> 1.9.1

OK on all three.

^ permalink raw reply

* Re: [PATCH 04/10] i2c: i2c-mux-i2cs: Add device tree bindings
From: Pantelis Antoniou @ 2016-10-17 19:11 UTC (permalink / raw)
  To: Peter Rosin
  Cc: Lee Jones, Linus Walleij, Alexandre Courbot, Rob Herring,
	Mark Rutland, Frank Rowand, Wolfram Sang, Richard Purdie,
	Jacek Anaszewski, Jean Delvare, Avirup Banerjee, Georgi Vlaev,
	Guenter Roeck, JawaharBalaji Thirumalaisamy, devicetree,
	linux-kernel, linux-gpio, linux-i2c, linux-leds, linux-hwmon
In-Reply-To: <83dc46b5-9c37-2813-0eca-267250e7cf2e@axentia.se>

Hi Rob,

> On Oct 10, 2016, at 18:48 , Peter Rosin <peda@axentia.se> wrote:
> 
> On 2016-10-07 17:21, Pantelis Antoniou wrote:
>> From: Georgi Vlaev <gvlaev@juniper.net>
>> 
>> Add binding document for the i2c mux driver of Juniper's I2CS FPGA.
>> 
>> Signed-off-by: Georgi Vlaev <gvlaev@juniper.net>
>> [Ported from Juniper kernel]
>> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
>> ---
>> .../devicetree/bindings/i2c/jnx,i2c-mux-i2cs.txt   | 27 ++++++++++++++++++++++
>> 1 file changed, 27 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/i2c/jnx,i2c-mux-i2cs.txt
>> 
>> diff --git a/Documentation/devicetree/bindings/i2c/jnx,i2c-mux-i2cs.txt b/Documentation/devicetree/bindings/i2c/jnx,i2c-mux-i2cs.txt
>> new file mode 100644
>> index 0000000..03d917f
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/i2c/jnx,i2c-mux-i2cs.txt
>> @@ -0,0 +1,27 @@
>> +* Juniper I2C Mux on I2CS
>> +
>> +	I2C mux driver for switching the RE access to the FPC i2c bus.
>> +	Compatible with the FPC variant of the I2CS.
>> +
>> +Required properties:
>> +
>> +  - compatible: "jnx,i2cs-mux-i2cs".
> 
> jnx,i2c-mux-i2cs
> 

OK.

>> +
>> +The following required properties are defined externally:
>> +
>> +  - Standard I2C mux properties. See i2c-mux.txt in this directory.
> 
> To accommodate changes pending for 4.9, change "mux" to "gate" in
> this line…
> 

OK, interesting.


>> +  - I2C child bus nodes. See i2c-mux.txt in this directory.
> 
> This line is wrong since the child nodes themselves are optional in
> i2c-gate.txt (and i2c-mux.txt). I guess you can just drop it since
> the child nodes are mentioned in i2c-gate.txt (and i2c-mux.txt).
> 

OK then.

>> +
>> +Example:
>> +
>> +fpc0_mux {
>> +	compatible = "jnx,i2c-mux-i2cs";
>> +	#address-cells = <1>;
>> +	#size-cells = <0>;
> 
> ...drop these two...
> 
>> +
>> +	fpc0i2c0: i2c@0 {
> 
> ...change i2c@0 to i2c-gate...
> 
>> +		#address-cells = <1>;
>> +		#size-cells = <0>;
>> +		reg = <0>;
> 
> ...and drop reg.
> 
> Cheers,
> Peter
> 

OK on all.

>> +	};
>> +};


^ permalink raw reply

* Re: [PATCH 02/10] mfd: dt-bindings: Add bindings for the Juniper I2CS MFD
From: Pantelis Antoniou @ 2016-10-17 19:10 UTC (permalink / raw)
  To: Rob Herring
  Cc: Lee Jones, Linus Walleij, Alexandre Courbot, Mark Rutland,
	Frank Rowand, Wolfram Sang, Richard Purdie, Jacek Anaszewski,
	Jean Delvare, Peter Rosin, Avirup Banerjee, Georgi Vlaev,
	Guenter Roeck, JawaharBalaji Thirumalaisamy, devicetree,
	linux-kernel, linux-gpio, linux-i2c, linux-leds, linux-hwmon
In-Reply-To: <20161010202341.GA5652@rob-hp-laptop>

Hi Rob,

> On Oct 10, 2016, at 23:23 , Rob Herring <robh@kernel.org> wrote:
> 
> On Fri, Oct 07, 2016 at 06:21:01PM +0300, Pantelis Antoniou wrote:
>> From: Georgi Vlaev <gvlaev@juniper.net>
>> 
>> Add device tree bindings for the Juniper I2CS MFD driver.
>> 
>> Signed-off-by: Georgi Vlaev <gvlaev@juniper.net>
>> [Ported from Juniper kernel]
>> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
>> ---
>> Documentation/devicetree/bindings/mfd/jnx-i2cs.txt | 68 ++++++++++++++++++++++
>> 1 file changed, 68 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/mfd/jnx-i2cs.txt
>> 
>> diff --git a/Documentation/devicetree/bindings/mfd/jnx-i2cs.txt b/Documentation/devicetree/bindings/mfd/jnx-i2cs.txt
>> new file mode 100644
>> index 0000000..0ec103b
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/mfd/jnx-i2cs.txt
>> @@ -0,0 +1,68 @@
>> +Device-Tree bindings for Juniper Networks I2CS FPGA MFD
>> +
>> +Required properties:
>> +- compatible - Must be one of:
>> +	"jnx,i2cs-rcb"	(Routing Engine or Control Board FRUs)
>> +	"jnx,i2cs-fpc"	(Flexible Port Concentrator FRUs)
>> +	"jnx,i2cs-sib"	(Switching Interface Board FRUs)
>> +	"jnx,i2cs-fan"	(Fan Tray FRUs)
>> +
>> +Optional properties:
>> +
>> +Depending on the FRU, the I2CS MFD has varied group of sub-devices:
>> +
>> +Device                   Description
>> +------                   -----------
>> +jnx,i2cs-gpio		: Virtual gpio mapping driver
>> +jnx,i2cs-fan-hwmon	: hwmon driver for fan trays
>> +jnx,i2c-mux-i2cs	: I2C Mux driver for FPC FRUs
>> +jnx,leds-i2cs		: Led driver
>> +
>> +All these optional nodes are described in their respective binding
>> +documents.
>> +
>> +Example node:
>> +
>> +i2cs@54 {
>> +	compatible = "jnx,i2cs-fpc";
>> +	reg = <0x54>;
>> +	#address-cells = <0>;
>> +	#size-cells = <0>;
>> +
>> +	fpc2_mux {
> 
> Generic node names please.
> 

OK.

> mux { 
> 
>> +		compatible = "jnx,i2c-mux-i2cs";
>> +		#address-cells = <1>;
>> +		#size-cells = <0>;
>> +
>> +		fpc2i2c0: i2c@0 {
>> +			#address-cells = <1>;
>> +			#size-cells = <0>;
>> +			reg = <0>;
>> +		};
>> +	};
>> +
>> +	fpc2_gpiomap: gpio-jnx-i2cs {
> 
> gpio@54 {
> 
OK

>> +		compatible = "jnx,gpio-i2cs";
>> +		reg = <0x54>;
>> +		#gpio-cells = <2>;
>> +		gpio-controller;
>> +		interrupt-controller;
>> +
>> +		/*
>> +		 * Map bits [0-3] of reg 0x21 as gpio inputs, bits [4-7]
>> +		 * as gpio outputs
>> +		 */
>> +		i2c-gpio-map = <0x21 0x0f>;
>> +	};
>> +
>> +	leds-jnx-i2cs {
> 
> leds {
> 

OK.

>> +		compatible = "jnx,leds-i2cs";
>> +		#address-cells = <1>;
>> +		#size-cells = <0>;
>> +
>> +		sib8-active {
>> +			reg = <0>;
>> +			linux,default-trigger = "sib8-active";
>> +		};
>> +	};
>> +};
>> -- 
>> 1.9.1

^ permalink raw reply

* Re: [PATCH 4/4] gpio: ptxpmb-ext-cpld: Document bindings of PTXPMB extended CPLD
From: Pantelis Antoniou @ 2016-10-17 19:10 UTC (permalink / raw)
  To: Rob Herring
  Cc: Lee Jones, Linus Walleij, Alexandre Courbot, Mark Rutland,
	Frank Rowand, Georgi Vlaev, Guenter Roeck,
	JawaharBalaji Thirumalaisamy, devicetree, linux-kernel,
	linux-gpio, linux-i2c, linux-mtd, linux-watchdog, netdev
In-Reply-To: <20161010201936.GB32418@rob-hp-laptop>

Hi Rob,

> On Oct 10, 2016, at 23:19 , Rob Herring <robh@kernel.org> wrote:
> 
> On Fri, Oct 07, 2016 at 06:19:34PM +0300, Pantelis Antoniou wrote:
>> From: Georgi Vlaev <gvlaev@juniper.net>
>> 
>> Add device tree bindings document for the GPIO driver of
>> Juniper's PTXPMB extended CPLD.
>> 
>> Signed-off-by: Georgi Vlaev <gvlaev@juniper.net>
>> [Ported from Juniper kernel]
>> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
>> ---
>> .../bindings/gpio/jnx,gpio-ptxpmb-ext-cpld.txt     | 36 ++++++++++++++++++++++
>> 1 file changed, 36 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/gpio/jnx,gpio-ptxpmb-ext-cpld.txt
>> 
>> diff --git a/Documentation/devicetree/bindings/gpio/jnx,gpio-ptxpmb-ext-cpld.txt b/Documentation/devicetree/bindings/gpio/jnx,gpio-ptxpmb-ext-cpld.txt
>> new file mode 100644
>> index 0000000..87f01b9
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/gpio/jnx,gpio-ptxpmb-ext-cpld.txt
>> @@ -0,0 +1,36 @@
>> +Juniper PTXPMB extended CPLD GPIO block
>> +
>> +Required properties:
>> +
>> +- compatible:
>> +    Must be "jnx,gpio-ptxpmb-ext-cpld"
> 
> Generally, '-gpio' would be last.
> 

OK.


>> +
>> +- #gpio-cells:
>> +    Should be <2>.  The first cell is the pin number (within the controller's
>> +    pin space), and the second is used for the following flags:
>> +	bit[0]: direction (0 = out, 1 = in)
>> +	bit[1]: init high
>> +	bit[2]: active low
> 
> Same comment as all the other gpio bindings...
> 
>> +
>> +- gpio-controller:
>> +    Specifies that the node is a GPIO controller.
>> +
>> +- interrupt-controller:
>> +    Specifies that the node is an interrupt controller.
>> +
>> +Optional properties:
>> +
>> +- reg:
>> +    Address and length of the register set for the device. Usually supplied
>> +    by the parent MFD device.
> 
> Make it required.
> 

Hmm, the current driver supplies that range via platform data (it’s an mfd driver).
What’s the take on mixing those?

>> +
>> +
>> +Example:
>> +
>> +gpio_ext_cpld: cpld-ext-gpio {
>> +	compatible = "jnx,gpio-ptxpmb-ext-cpld";
>> +	#gpio-cells = <2>;
>> +	#interrupt-cells = <2>;
>> +	gpio-controller;
>> +	interrupt-controller;
>> +};
>> -- 
>> 1.9.1

^ permalink raw reply

* Re: [PATCH 2/4] mfd: ptxpmb-ext-cpld: Add documentation for PTXPMB extended CPLD
From: Pantelis Antoniou @ 2016-10-17 19:08 UTC (permalink / raw)
  To: Rob Herring
  Cc: Lee Jones, Linus Walleij, Alexandre Courbot, Mark Rutland,
	Frank Rowand, Georgi Vlaev, Guenter Roeck,
	JawaharBalaji Thirumalaisamy, devicetree, linux-kernel,
	linux-gpio, linux-i2c, linux-mtd, linux-watchdog, netdev
In-Reply-To: <20161010201031.GA31318@rob-hp-laptop>

Hi Rob,

> On Oct 10, 2016, at 23:10 , Rob Herring <robh@kernel.org> wrote:
> 
> On Fri, Oct 07, 2016 at 06:19:32PM +0300, Pantelis Antoniou wrote:
>> From: Georgi Vlaev <gvlaev@juniper.net>
>> 
>> Add DT bindings document for the PTXPMB extended CPLD device.
>> 
>> Signed-off-by: Georgi Vlaev <gvlaev@juniper.net>
>> [Ported from Juniper kernel]
>> Signed-off-by: Pantelis Antoniou <pantelis.antoniou@konsulko.com>
>> ---
>> .../bindings/mfd/jnx-ptxpmb-ext-cpld.txt           | 35 ++++++++++++++++++++++
>> 1 file changed, 35 insertions(+)
>> create mode 100644 Documentation/devicetree/bindings/mfd/jnx-ptxpmb-ext-cpld.txt
>> 
>> diff --git a/Documentation/devicetree/bindings/mfd/jnx-ptxpmb-ext-cpld.txt b/Documentation/devicetree/bindings/mfd/jnx-ptxpmb-ext-cpld.txt
>> new file mode 100644
>> index 0000000..098a548a
>> --- /dev/null
>> +++ b/Documentation/devicetree/bindings/mfd/jnx-ptxpmb-ext-cpld.txt
>> @@ -0,0 +1,35 @@
>> +* Device tree bindings for Juniper's PTXPMB Extended CPLD FPGA MFD driver
>> +
>> +The device supports a gpio block which is described in the
>> +jnx-gpio-ptxpmb-ext-cpld document.
>> +
>> +Required properties:
>> +
>> +- compatible:		"jnx,ptxpmb-ext-cpld"
>> +
>> +- reg:			contains offset/length value for device state control
>> +			registers space.
>> +
>> +Optional properties:
>> +
>> +- interrupts:		The interrupt line(s) the /IRQ signal(s) for the device is
>> +			connected to.
>> +
>> +- interrupt-parent:	The parent interrupt controller.
>> +
>> +Example:
>> +
>> +ext-cpld@1,0 {
>> +	compatible = "jnx,ptxpmb-ext-cpld";
>> +	reg = <0x1 0 0x1000>;
> 
> What's the bus type here? Unit address is probably wrong.
> 

localbus on a gpmc memory controller.

>> +	interrupt-parent = <&mpic>;
>> +	interrupts = <7 2>, <8 2>;
>> +
>> +	gpio_ext_cpld: cpld-ext-gpio {
>> +		compatible = "jnx,gpio-ptxpmb-ext-cpld";
>> +		#gpio-cells = <2>;
>> +		#interrupt-cells = <2>;
>> +		gpio-controller;
>> +		interrupt-controller;
>> +	};
>> +};
>> -- 
>> 1.9.1


^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox