linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers
@ 2014-11-18 18:06 Felipe Balbi
  2014-11-18 18:07 ` [PATCH 02/10] arm: omap: omap2plus_defconfig: enable EDT FT5X06 touchscreen Felipe Balbi
                   ` (8 more replies)
  0 siblings, 9 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:06 UTC (permalink / raw)
  To: linux-arm-kernel

None of these drivers are known to be used on
any platform supported by omap2plus_defconfig,
by removing them we get a slight smaller kernel.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---

Depends on [1]

[1] http://marc.info/?l=linux-omap&m=141632534806371&w=2

 arch/arm/configs/omap2plus_defconfig | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig
index 82dc4d6..24d6fe2 100644
--- a/arch/arm/configs/omap2plus_defconfig
+++ b/arch/arm/configs/omap2plus_defconfig
@@ -129,11 +129,27 @@ CONFIG_BLK_DEV_SD=y
 CONFIG_SCSI_SCAN_ASYNC=y
 CONFIG_MD=y
 CONFIG_NETDEVICES=y
+# CONFIG_NET_VENDOR_ARC is not set
+# CONFIG_NET_CADENCE is not set
+# CONFIG_NET_VENDOR_BROADCOM is not set
+# CONFIG_NET_VENDOR_CIRRUS is not set
+# CONFIG_NET_VENDOR_FARADAY is not set
+# CONFIG_NET_VENDOR_HISILICON is not set
+# CONFIG_NET_VENDOR_INTEL is not set
+# CONFIG_NET_VENDOR_MARVELL is not set
 CONFIG_KS8851=y
 CONFIG_KS8851_MLL=y
+# CONFIG_NET_VENDOR_MICROCHIP is not set
+# CONFIG_NET_VENDOR_NATSEMI is not set
+# CONFIG_NET_VENDOR_QUALCOMM is not set
+# CONFIG_NET_VENDOR_SAMSUNG is not set
+# CONFIG_NET_VENDOR_SEEQ is not set
 CONFIG_SMC91X=y
 CONFIG_SMSC911X=y
+# CONFIG_NET_VENDOR_STMICRO is not set
 CONFIG_TI_CPSW=y
+# CONFIG_NET_VENDOR_VIA is not set
+# CONFIG_NET_VENDOR_WIZNET is not set
 CONFIG_AT803X_PHY=y
 CONFIG_SMSC_PHY=y
 CONFIG_USB_USBNET=y
-- 
2.1.0.GIT

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

* [PATCH 02/10] arm: omap: omap2plus_defconfig: enable EDT FT5X06 touchscreen
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 03/10] arm: omap: omap2plus_defconfig: enable AM33XX SoC sound Felipe Balbi
                   ` (7 subsequent siblings)
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

AM437x Starter Kit ships with EDT FT5306 touchscreen
device. By enabling the driver we make sure touchscreen
will work out of the box.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/configs/omap2plus_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig
index 24d6fe2..c893487 100644
--- a/arch/arm/configs/omap2plus_defconfig
+++ b/arch/arm/configs/omap2plus_defconfig
@@ -177,6 +177,7 @@ CONFIG_KEYBOARD_MATRIX=m
 CONFIG_KEYBOARD_TWL4030=y
 CONFIG_INPUT_TOUCHSCREEN=y
 CONFIG_TOUCHSCREEN_ADS7846=m
+CONFIG_TOUCHSCREEN_EDT_FT5X06=m
 CONFIG_TOUCHSCREEN_TSC2005=m
 CONFIG_TOUCHSCREEN_TSC2007=m
 CONFIG_INPUT_MISC=y
-- 
2.1.0.GIT

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

* [PATCH 03/10] arm: omap: omap2plus_defconfig: enable AM33XX SoC sound
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
  2014-11-18 18:07 ` [PATCH 02/10] arm: omap: omap2plus_defconfig: enable EDT FT5X06 touchscreen Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 04/10] arm: omap: omap2plus_defconfig: enable XHCI Felipe Balbi
                   ` (6 subsequent siblings)
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

Without this, sound on AM437x Starter Kit will
not work.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/configs/omap2plus_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig
index c893487..a5abc67 100644
--- a/arch/arm/configs/omap2plus_defconfig
+++ b/arch/arm/configs/omap2plus_defconfig
@@ -281,6 +281,8 @@ CONFIG_SND_VERBOSE_PRINTK=y
 CONFIG_SND_DEBUG=y
 CONFIG_SND_USB_AUDIO=m
 CONFIG_SND_SOC=m
+CONFIG_SND_EDMA_SOC=m
+CONFIG_SND_AM33XX_SOC_EVM=m
 CONFIG_SND_OMAP_SOC=m
 CONFIG_SND_OMAP_SOC_OMAP_TWL4030=m
 CONFIG_SND_OMAP_SOC_OMAP_ABE_TWL6040=m
-- 
2.1.0.GIT

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

* [PATCH 04/10] arm: omap: omap2plus_defconfig: enable XHCI
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
  2014-11-18 18:07 ` [PATCH 02/10] arm: omap: omap2plus_defconfig: enable EDT FT5X06 touchscreen Felipe Balbi
  2014-11-18 18:07 ` [PATCH 03/10] arm: omap: omap2plus_defconfig: enable AM33XX SoC sound Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM Felipe Balbi
                   ` (5 subsequent siblings)
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

AM437x devices have a DWC3 IP inside of them.

The host side implementation of DWC3 is XHCI
compliant. By enabling XHCI driver, we get
the USB host port on AM437x Starter Kit working
out of the box.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/configs/omap2plus_defconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig
index a5abc67..3837a3e 100644
--- a/arch/arm/configs/omap2plus_defconfig
+++ b/arch/arm/configs/omap2plus_defconfig
@@ -292,6 +292,7 @@ CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
 CONFIG_USB_DYNAMIC_MINORS=y
 CONFIG_USB_OTG=y
 CONFIG_USB_MON=y
+CONFIG_USB_XHCI_HCD=m
 CONFIG_USB_WDM=y
 CONFIG_USB_STORAGE=y
 CONFIG_USB_MUSB_HDRC=m
-- 
2.1.0.GIT

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

* [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (2 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 04/10] arm: omap: omap2plus_defconfig: enable XHCI Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-22  0:31   ` Tony Lindgren
  2014-11-18 18:07 ` [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing Felipe Balbi
                   ` (4 subsequent siblings)
  8 siblings, 1 reply; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

Many of AM335x and AM437x hook backlight to
one of these two devices. By enabling their
drivers we make sure pwm-backlight can do
its thing.

Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/configs/omap2plus_defconfig | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arch/arm/configs/omap2plus_defconfig b/arch/arm/configs/omap2plus_defconfig
index 3837a3e..9be67b7 100644
--- a/arch/arm/configs/omap2plus_defconfig
+++ b/arch/arm/configs/omap2plus_defconfig
@@ -401,6 +401,8 @@ CONFIG_DMA_OMAP=y
 CONFIG_EXTCON=y
 CONFIG_EXTCON_PALMAS=y
 CONFIG_PWM=y
+CONFIG_PWM_TIECAP=y
+CONFIG_PWM_TIEHRPWM=y
 CONFIG_PWM_TWL=y
 CONFIG_PWM_TWL_LED=y
 CONFIG_OMAP_USB2=y
-- 
2.1.0.GIT

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

* [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (3 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:38   ` Dmitry Torokhov
  2014-11-18 18:07 ` [PATCH 07/10] arm: boot: dts: am437x-sk: switch over to new edt-ft5306 compatible Felipe Balbi
                   ` (3 subsequent siblings)
  8 siblings, 1 reply; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

i2c devices match against struct i2c_device_id
even for CONFIG_OF case, so adding a struct of_device_id
doesn't change anything. As a result, currently, edt-ft5x06
will not autoprobe if built as a module.

To fix the issue and still maintain backwards compatibility
with all DTS files currently in tree, we're just moving
all ids from of_device_id to i2c_device_id while also
adding the following specific ids which should be used
from now on:

	{ "edt-ft5206", 0, }
	{ "edt-ft5306", 0, }
	{ "edt-ft5406", 0, }

Cc: Lothar Wa?mann <lw@karo-electronics.de>
Cc: Rob Herring <robh+dt@kernel.org>
Cc: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Cc: <devicetree@vger.kernel.org>
Cc: <linux-input@vger.kernel.org>
Cc: <stable@vger.kernel.org> # v3.15+
Fixes: dac90dc2 (Input: edt-ft5x06 - add DT support)
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 .../bindings/input/touchscreen/edt-ft5x06.txt           |  9 ++++++---
 drivers/input/touchscreen/edt-ft5x06.c                  | 17 ++++++-----------
 2 files changed, 12 insertions(+), 14 deletions(-)

diff --git a/Documentation/devicetree/bindings/input/touchscreen/edt-ft5x06.txt b/Documentation/devicetree/bindings/input/touchscreen/edt-ft5x06.txt
index 76db967..50bd5d2 100644
--- a/Documentation/devicetree/bindings/input/touchscreen/edt-ft5x06.txt
+++ b/Documentation/devicetree/bindings/input/touchscreen/edt-ft5x06.txt
@@ -14,9 +14,12 @@ bindings.
 
 
 Required properties:
- - compatible:  "edt,edt-ft5206"
-           or:  "edt,edt-ft5306"
-           or:  "edt,edt-ft5406"
+ - compatible:  "edt-ft5206"
+	   or:  "edt-ft5306"
+	   or:  "edt-ft5406"
+	   or:  "edt,edt-ft5206" (deprecated)
+           or:  "edt,edt-ft5306" (deprecated)
+           or:  "edt,edt-ft5406" (deprecated)
 
  - reg:         I2C slave address of the chip (0x38)
  - interrupt-parent: a phandle pointing to the interrupt controller
diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c
index ee3434f..f161ff9 100644
--- a/drivers/input/touchscreen/edt-ft5x06.c
+++ b/drivers/input/touchscreen/edt-ft5x06.c
@@ -1119,25 +1119,20 @@ static SIMPLE_DEV_PM_OPS(edt_ft5x06_ts_pm_ops,
 
 static const struct i2c_device_id edt_ft5x06_ts_id[] = {
 	{ "edt-ft5x06", 0, },
+	{ "edt-ft5206", 0, },
+	{ "edt-ft5306", 0, },
+	{ "edt-ft5406", 0, },
+	{ "edt,edt-ft5206", 0, },
+	{ "edt,edt-ft5306", 0, },
+	{ "edt,edt-ft5406", 0, },
 	{ /* sentinel */ }
 };
 MODULE_DEVICE_TABLE(i2c, edt_ft5x06_ts_id);
 
-#ifdef CONFIG_OF
-static const struct of_device_id edt_ft5x06_of_match[] = {
-	{ .compatible = "edt,edt-ft5206", },
-	{ .compatible = "edt,edt-ft5306", },
-	{ .compatible = "edt,edt-ft5406", },
-	{ /* sentinel */ }
-};
-MODULE_DEVICE_TABLE(of, edt_ft5x06_of_match);
-#endif
-
 static struct i2c_driver edt_ft5x06_ts_driver = {
 	.driver = {
 		.owner = THIS_MODULE,
 		.name = "edt_ft5x06",
-		.of_match_table = of_match_ptr(edt_ft5x06_of_match),
 		.pm = &edt_ft5x06_ts_pm_ops,
 	},
 	.id_table = edt_ft5x06_ts_id,
-- 
2.1.0.GIT

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

* [PATCH 07/10] arm: boot: dts: am437x-sk: switch over to new edt-ft5306 compatible
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (4 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 08/10] arm: boot: dts: imx28-tx28: switch over to new edt-ft5x06 compatible Felipe Balbi
                   ` (2 subsequent siblings)
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

now that we have the new vendor-less edt-ft5306
i2c_device_id, we can use it

Cc: <devicetree@vger.kernel.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/boot/dts/am437x-sk-evm.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/am437x-sk-evm.dts b/arch/arm/boot/dts/am437x-sk-evm.dts
index 859ff3d..26133cb 100644
--- a/arch/arm/boot/dts/am437x-sk-evm.dts
+++ b/arch/arm/boot/dts/am437x-sk-evm.dts
@@ -404,7 +404,7 @@
 
 	edt-ft5306 at 38 {
 		status = "okay";
-		compatible = "edt,edt-ft5306", "edt,edt-ft5x06";
+		compatible = "edt-ft5306", "edt-ft5x06";
 		pinctrl-names = "default";
 		pinctrl-0 = <&edt_ft5306_ts_pins>;
 
-- 
2.1.0.GIT

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

* [PATCH 08/10] arm: boot: dts: imx28-tx28: switch over to new edt-ft5x06 compatible
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (5 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 07/10] arm: boot: dts: am437x-sk: switch over to new edt-ft5306 compatible Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 09/10] arm: boot: dts: imx53-tx53-x03x: " Felipe Balbi
  2014-11-18 18:07 ` [PATCH 10/10] arm: boot: dts: imx6qdl-tx6: " Felipe Balbi
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

now that we have the new vendor-less edt-ft5x06
i2c_device_id, we can use it

Cc: <devicetree@vger.kernel.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/boot/dts/imx28-tx28.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx28-tx28.dts b/arch/arm/boot/dts/imx28-tx28.dts
index a5b27c8..5c5c988 100644
--- a/arch/arm/boot/dts/imx28-tx28.dts
+++ b/arch/arm/boot/dts/imx28-tx28.dts
@@ -319,7 +319,7 @@
 	};
 
 	polytouch: edt-ft5x06 at 38 {
-		compatible = "edt,edt-ft5x06";
+		compatible = "edt-ft5x06";
 		reg = <0x38>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&tx28_edt_ft5x06_pins>;
-- 
2.1.0.GIT

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

* [PATCH 09/10] arm: boot: dts: imx53-tx53-x03x: switch over to new edt-ft5x06 compatible
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (6 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 08/10] arm: boot: dts: imx28-tx28: switch over to new edt-ft5x06 compatible Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  2014-11-18 18:07 ` [PATCH 10/10] arm: boot: dts: imx6qdl-tx6: " Felipe Balbi
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

now that we have the new vendor-less edt-ft5x06
i2c_device_id, we can use it

Cc: <devicetree@vger.kernel.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/boot/dts/imx53-tx53-x03x.dts | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx53-tx53-x03x.dts b/arch/arm/boot/dts/imx53-tx53-x03x.dts
index 3b73e81..27bf29d 100644
--- a/arch/arm/boot/dts/imx53-tx53-x03x.dts
+++ b/arch/arm/boot/dts/imx53-tx53-x03x.dts
@@ -211,7 +211,7 @@
 	};
 
 	polytouch: edt-ft5x06 at 38 {
-		compatible = "edt,edt-ft5x06";
+		compatible = "edt-ft5x06";
 		reg = <0x38>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_edt_ft5x06_1>;
-- 
2.1.0.GIT

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

* [PATCH 10/10] arm: boot: dts: imx6qdl-tx6: switch over to new edt-ft5x06 compatible
  2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
                   ` (7 preceding siblings ...)
  2014-11-18 18:07 ` [PATCH 09/10] arm: boot: dts: imx53-tx53-x03x: " Felipe Balbi
@ 2014-11-18 18:07 ` Felipe Balbi
  8 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 18:07 UTC (permalink / raw)
  To: linux-arm-kernel

now that we have the new vendor-less edt-ft5x06
i2c_device_id, we can use it

Cc: <devicetree@vger.kernel.org>
Signed-off-by: Felipe Balbi <balbi@ti.com>
---
 arch/arm/boot/dts/imx6qdl-tx6.dtsi | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/imx6qdl-tx6.dtsi b/arch/arm/boot/dts/imx6qdl-tx6.dtsi
index f02b80b..5ecf3bf 100644
--- a/arch/arm/boot/dts/imx6qdl-tx6.dtsi
+++ b/arch/arm/boot/dts/imx6qdl-tx6.dtsi
@@ -267,7 +267,7 @@
 	};
 
 	polytouch: edt-ft5x06 at 38 {
-		compatible = "edt,edt-ft5x06";
+		compatible = "edt-ft5x06";
 		reg = <0x38>;
 		pinctrl-names = "default";
 		pinctrl-0 = <&pinctrl_edt_ft5x06>;
-- 
2.1.0.GIT

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

* [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing
  2014-11-18 18:07 ` [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing Felipe Balbi
@ 2014-11-18 18:38   ` Dmitry Torokhov
  2014-11-18 19:09     ` Felipe Balbi
  0 siblings, 1 reply; 14+ messages in thread
From: Dmitry Torokhov @ 2014-11-18 18:38 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Felipe,

On Tue, Nov 18, 2014 at 12:07:04PM -0600, Felipe Balbi wrote:
> i2c devices match against struct i2c_device_id
> even for CONFIG_OF case, so adding a struct of_device_id
> doesn't change anything. As a result, currently, edt-ft5x06
> will not autoprobe if built as a module.

Why doe snot it autoprobe? We properly declare MODULE_DEVICE_TABLE for
OF, is it because we are missing some data in device uevent?

> 
> To fix the issue and still maintain backwards compatibility
> with all DTS files currently in tree, we're just moving
> all ids from of_device_id to i2c_device_id while also
> adding the following specific ids which should be used
> from now on:
> 
> 	{ "edt-ft5206", 0, }
> 	{ "edt-ft5306", 0, }
> 	{ "edt-ft5406", 0, }

Is this a tee-wide change? Link to the discussion?

Thanks.

-- 
Dmitry

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

* [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing
  2014-11-18 18:38   ` Dmitry Torokhov
@ 2014-11-18 19:09     ` Felipe Balbi
  2014-11-18 19:21       ` Felipe Balbi
  0 siblings, 1 reply; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 19:09 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Nov 18, 2014 at 10:38:47AM -0800, Dmitry Torokhov wrote:
> Hi Felipe,
> 
> On Tue, Nov 18, 2014 at 12:07:04PM -0600, Felipe Balbi wrote:
> > i2c devices match against struct i2c_device_id
> > even for CONFIG_OF case, so adding a struct of_device_id
> > doesn't change anything. As a result, currently, edt-ft5x06
> > will not autoprobe if built as a module.
> 
> Why doe snot it autoprobe? We properly declare MODULE_DEVICE_TABLE for
> OF, is it because we are missing some data in device uevent?

because of of_i2c_register_devices(). Maybe Wolfram can give a better
explanation here, but it just doesn't match through of_device_id.

Apply this:

diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index 2f90ac6..f0dc16e 100644
--- a/drivers/i2c/i2c-core.c
+++ b/drivers/i2c/i2c-core.c
@@ -449,8 +449,10 @@ static const struct i2c_device_id *i2c_match_id(const struct i2c_device_id *id,
 						const struct i2c_client *client)
 {
 	while (id->name[0]) {
-		if (strcmp(client->name, id->name) == 0)
+		if (strcmp(client->name, id->name) == 0) {
+			dev_info(&client->dev, "i2c_device_id match\n");
 			return id;
+		}
 		id++;
 	}
 	return NULL;
@@ -465,8 +467,10 @@ static int i2c_device_match(struct device *dev, struct device_driver *drv)
 		return 0;
 
 	/* Attempt an OF style match */
-	if (of_driver_match_device(dev, drv))
+	if (of_driver_match_device(dev, drv)) {
+		dev_info(dev, "of driver match\n");
 		return 1;
+	}
 
 	/* Then ACPI style match */
 	if (acpi_driver_match_device(dev, drv))
@@ -1081,6 +1085,7 @@ i2c_new_device(struct i2c_adapter *adap, struct i2c_board_info const *info)
 	client->dev.bus = &i2c_bus_type;
 	client->dev.type = &i2c_client_type;
 	client->dev.of_node = info->of_node;
+	dev_info(&adap->dev, "%s: of_node %p\n", __func__, info->of_node);
 	ACPI_COMPANION_SET(&client->dev, info->acpi_node.companion);
 
 	i2c_dev_set_name(adap, client);
@@ -1411,6 +1416,7 @@ static void of_i2c_register_devices(struct i2c_adapter *adap)
 
 		info.irq = irq_of_parse_and_map(node, 0);
 		info.of_node = of_node_get(node);
+		dev_info(&adap->dev, "%s: of_node %p\n", __func__, info.of_node);
 		info.archdata = &dev_ad;
 
 		if (of_get_property(node, "wakeup-source", NULL))

then boot the board and you get http://hastebin.com/oqemezajez

Interesting, it's matching against of but only when I modprobe.

Let me debug this one a little more.

> > To fix the issue and still maintain backwards compatibility
> > with all DTS files currently in tree, we're just moving
> > all ids from of_device_id to i2c_device_id while also
> > adding the following specific ids which should be used
> > from now on:
> > 
> > 	{ "edt-ft5206", 0, }
> > 	{ "edt-ft5306", 0, }
> > 	{ "edt-ft5406", 0, }
> 
> Is this a tee-wide change? Link to the discussion?

nope, just found it with my AM437x Starter Kit.

-- 
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20141118/743c97ad/attachment.sig>

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

* [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing
  2014-11-18 19:09     ` Felipe Balbi
@ 2014-11-18 19:21       ` Felipe Balbi
  0 siblings, 0 replies; 14+ messages in thread
From: Felipe Balbi @ 2014-11-18 19:21 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

On Tue, Nov 18, 2014 at 01:09:22PM -0600, Felipe Balbi wrote:
> On Tue, Nov 18, 2014 at 10:38:47AM -0800, Dmitry Torokhov wrote:
> > Hi Felipe,
> > 
> > On Tue, Nov 18, 2014 at 12:07:04PM -0600, Felipe Balbi wrote:
> > > i2c devices match against struct i2c_device_id
> > > even for CONFIG_OF case, so adding a struct of_device_id
> > > doesn't change anything. As a result, currently, edt-ft5x06
> > > will not autoprobe if built as a module.
> > 
> > Why doe snot it autoprobe? We properly declare MODULE_DEVICE_TABLE for
> > OF, is it because we are missing some data in device uevent?
> 
> because of of_i2c_register_devices(). Maybe Wolfram can give a better
> explanation here, but it just doesn't match through of_device_id.
> 
> Apply this:
> 
> diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
> index 2f90ac6..f0dc16e 100644
> --- a/drivers/i2c/i2c-core.c
> +++ b/drivers/i2c/i2c-core.c
> @@ -449,8 +449,10 @@ static const struct i2c_device_id *i2c_match_id(const struct i2c_device_id *id,
>  						const struct i2c_client *client)
>  {
>  	while (id->name[0]) {
> -		if (strcmp(client->name, id->name) == 0)
> +		if (strcmp(client->name, id->name) == 0) {
> +			dev_info(&client->dev, "i2c_device_id match\n");
>  			return id;
> +		}
>  		id++;
>  	}
>  	return NULL;
> @@ -465,8 +467,10 @@ static int i2c_device_match(struct device *dev, struct device_driver *drv)
>  		return 0;
>  
>  	/* Attempt an OF style match */
> -	if (of_driver_match_device(dev, drv))
> +	if (of_driver_match_device(dev, drv)) {
> +		dev_info(dev, "of driver match\n");
>  		return 1;
> +	}
>  
>  	/* Then ACPI style match */
>  	if (acpi_driver_match_device(dev, drv))
> @@ -1081,6 +1085,7 @@ i2c_new_device(struct i2c_adapter *adap, struct i2c_board_info const *info)
>  	client->dev.bus = &i2c_bus_type;
>  	client->dev.type = &i2c_client_type;
>  	client->dev.of_node = info->of_node;
> +	dev_info(&adap->dev, "%s: of_node %p\n", __func__, info->of_node);
>  	ACPI_COMPANION_SET(&client->dev, info->acpi_node.companion);
>  
>  	i2c_dev_set_name(adap, client);
> @@ -1411,6 +1416,7 @@ static void of_i2c_register_devices(struct i2c_adapter *adap)
>  
>  		info.irq = irq_of_parse_and_map(node, 0);
>  		info.of_node = of_node_get(node);
> +		dev_info(&adap->dev, "%s: of_node %p\n", __func__, info.of_node);
>  		info.archdata = &dev_ad;
>  
>  		if (of_get_property(node, "wakeup-source", NULL))
> 
> then boot the board and you get http://hastebin.com/oqemezajez
> 
> Interesting, it's matching against of but only when I modprobe.
> 
> Let me debug this one a little more.

this is a simpler patch:

+MODULE_ALIAS("i2c:edt-ft5206");
+MODULE_ALIAS("i2c:edt-ft5306");
+MODULE_ALIAS("i2c:edt-ft5406");

I'll send it in a bit.

-- 
balbi
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20141118/0b3f18f4/attachment.sig>

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

* [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM
  2014-11-18 18:07 ` [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM Felipe Balbi
@ 2014-11-22  0:31   ` Tony Lindgren
  0 siblings, 0 replies; 14+ messages in thread
From: Tony Lindgren @ 2014-11-22  0:31 UTC (permalink / raw)
  To: linux-arm-kernel

* Felipe Balbi <balbi@ti.com> [141118 10:08]:
> Many of AM335x and AM437x hook backlight to
> one of these two devices. By enabling their
> drivers we make sure pwm-backlight can do
> its thing.

Applying patches 1 - 5 to omap-for-v3.19/soc thanks.

Tony

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

end of thread, other threads:[~2014-11-22  0:31 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-11-18 18:06 [PATCH 01/10] arm: omap: omap2plus_defconfig: remove unwanted ethernet drivers Felipe Balbi
2014-11-18 18:07 ` [PATCH 02/10] arm: omap: omap2plus_defconfig: enable EDT FT5X06 touchscreen Felipe Balbi
2014-11-18 18:07 ` [PATCH 03/10] arm: omap: omap2plus_defconfig: enable AM33XX SoC sound Felipe Balbi
2014-11-18 18:07 ` [PATCH 04/10] arm: omap: omap2plus_defconfig: enable XHCI Felipe Balbi
2014-11-18 18:07 ` [PATCH 05/10] arm: omap: omap2plus_defconfig: enable ECAP and EHRPWM Felipe Balbi
2014-11-22  0:31   ` Tony Lindgren
2014-11-18 18:07 ` [PATCH 06/10] input: touchscreen: edt-ft5x06: fix driver autoprobing Felipe Balbi
2014-11-18 18:38   ` Dmitry Torokhov
2014-11-18 19:09     ` Felipe Balbi
2014-11-18 19:21       ` Felipe Balbi
2014-11-18 18:07 ` [PATCH 07/10] arm: boot: dts: am437x-sk: switch over to new edt-ft5306 compatible Felipe Balbi
2014-11-18 18:07 ` [PATCH 08/10] arm: boot: dts: imx28-tx28: switch over to new edt-ft5x06 compatible Felipe Balbi
2014-11-18 18:07 ` [PATCH 09/10] arm: boot: dts: imx53-tx53-x03x: " Felipe Balbi
2014-11-18 18:07 ` [PATCH 10/10] arm: boot: dts: imx6qdl-tx6: " Felipe Balbi

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