linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: sander@van-ginkel.eu (sander van ginkel)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] add hardware I2C support for ARM IMX23
Date: Wed, 28 Nov 2012 15:24:03 +0100	[thread overview]
Message-ID: <20121128152403.45224dvyaufb1j7n@62.129.139.42> (raw)

The I2C hardware in the IMX233 is currently not supported,
however the i2c-mxs driver seems to be suitable.
To use the i2c-mxs driver it has to be added to the devicetree
for the IMX23.


Signed-off-by: Sander van Ginkel <sander@van-ginkel.eu>
---
diff -Naur linux-3.7-rc6/arch/arm/boot/dts/imx23-olinuxino.dts  
linux-3.7-rc6-i2c/arch/arm/boot/dts/imx23-olinuxino.dts
--- linux-3.7-rc6/arch/arm/boot/dts/imx23-olinuxino.dts	2012-11-17  
01:42:40.000000000 +0000
+++ linux-3.7-rc6-i2c/arch/arm/boot/dts/imx23-olinuxino.dts	2012-11-24  
22:40:51.000000000 +0000
@@ -50,6 +50,13 @@
		};

		apbx at 80040000 {
+
+			i2c0: i2c at 80058000 {
+				pinctrl-names = "default";
+				pinctrl-0 = <&i2c0_pins_a>;
+				status = "okay";
+			};
+
			duart: serial at 80070000 {
				pinctrl-names = "default";
				pinctrl-0 = <&duart_pins_a>;
diff -Naur linux-3.7-rc6/arch/arm/boot/dts/imx23.dtsi  
linux-3.7-rc6-i2c/arch/arm/boot/dts/imx23.dtsi
--- linux-3.7-rc6/arch/arm/boot/dts/imx23.dtsi	2012-11-17  
01:42:40.000000000 +0000
+++ linux-3.7-rc6-i2c/arch/arm/boot/dts/imx23.dtsi	2012-11-24  
22:40:51.000000000 +0000
@@ -144,6 +144,17 @@
					fsl,pull-up = <0>;
				};

+				i2c0_pins_a: i2c0 at 0 {
+					reg = <0>;
+					fsl,pinmux-ids = <
+						0x1171 /* MX23_PAD_LCD_ENABLE__I2C_SCL */
+						0x1181 /* MX23_PAD_LCD_HSYNC__I2C_SDA */
+					>;
+					fsl,drive-strength = <1>;
+					fsl,voltage = <1>;
+					fsl,pull-up = <1>;
+				};
+
				auart0_2pins_a: auart0-2pins at 0 {
					reg = <0>;
					fsl,pinmux-ids = <
@@ -387,9 +398,15 @@
				status = "disabled";
			};

-			i2c at 80058000 {
+			i2c0: i2c@80058000 {
+				#address-cells = <2>;
+				#size-cells = <1>;
+				compatible = "fsl,imx28-i2c";
				reg = <0x80058000 0x2000>;
+				interrupts = <26 27>;
+				clock-frequency = <100000>;
				status = "disabled";
+				fsl,i2c-dma-channel = <3>;
			};

			rtc at 8005c000 {

             reply	other threads:[~2012-11-28 14:24 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-11-28 14:24 sander van ginkel [this message]
2012-11-28 15:08 ` [PATCH] add hardware I2C support for ARM IMX23 Wolfram Sang
2012-11-28 16:10   ` sander van ginkel
2012-11-28 16:24     ` Wolfram Sang
2012-11-28 16:44       ` Sander van Ginkel
2012-11-28 17:09         ` Wolfram Sang
2012-11-28 17:34           ` sander van ginkel
2012-11-30 16:32           ` sander van ginkel
2012-11-28 18:33         ` Tim Michals
2012-11-28 18:58           ` sander van ginkel
2012-11-28 19:15             ` Tim Michals

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20121128152403.45224dvyaufb1j7n@62.129.139.42 \
    --to=sander@van-ginkel.eu \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).