linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: andrew@lunn.ch (Andrew Lunn)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v3 2/5] ARM: kirkwood: Add i2c alias so setting bus number
Date: Tue, 25 Feb 2014 18:34:00 +0100	[thread overview]
Message-ID: <1393349643-6652-3-git-send-email-andrew@lunn.ch> (raw)
In-Reply-To: <1393349643-6652-1-git-send-email-andrew@lunn.ch>

When using platform_driver instantiation, the i2c bus was given bus
number 0. The kirkwood-t5325 audio driver has this bus number hard
coded for the address of the codec. However by default device tree i2c
busses are dynamically allocated a bus number, starting from 1. Thus
the kirkwood-t5325 cannot find its audio codec. By adding an alias in
the DT file we can control the bus number and set it to 0. The codec
can then be found.

Signed-off-by: Andrew Lunn <andrew@lunn.ch>
---
 arch/arm/boot/dts/kirkwood.dtsi | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm/boot/dts/kirkwood.dtsi b/arch/arm/boot/dts/kirkwood.dtsi
index 5a86fa820e12..90384587c278 100644
--- a/arch/arm/boot/dts/kirkwood.dtsi
+++ b/arch/arm/boot/dts/kirkwood.dtsi
@@ -24,6 +24,7 @@
 	aliases {
 	       gpio0 = &gpio0;
 	       gpio1 = &gpio1;
+	       i2c0 = &i2c0;
 	};
 
 	mbus {
@@ -111,7 +112,7 @@
 			clocks = <&gate_clk 7>;
 		};
 
-		i2c at 11000 {
+		i2c0: i2c at 11000 {
 			compatible = "marvell,mv64xxx-i2c";
 			reg = <0x11000 0x20>;
 			#address-cells = <1>;
-- 
1.8.5.3

  parent reply	other threads:[~2014-02-25 17:34 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-02-25 17:33 [PATCH v3 0/5] mvebu support for kirkwood HP T5325 Andrew Lunn
2014-02-25 17:33 ` [PATCH v3 1/5] ARM: kirkwood: Add audio node to kirkwood.dtsi Andrew Lunn
2014-02-25 17:34 ` Andrew Lunn [this message]
2014-02-25 17:34 ` [PATCH v3 3/5] ARM: kirkwood: Add HP T5325 thin client Andrew Lunn
2014-02-25 17:34 ` [PATCH v3 4/5] ARM: kirkwood: Add dts file describing " Andrew Lunn
2014-02-25 17:34 ` [PATCH v3 5/5] ARM: kirkwood: Add HP T5325 devices to {multi|mvebu}_v5_defconfig Andrew Lunn
2014-02-25 18:19   ` Arnd Bergmann
2014-02-25 18:53     ` Andrew Lunn
2014-02-25 19:04       ` Arnd Bergmann
2014-02-25 20:35 ` [PATCH v3 0/5] mvebu support for kirkwood HP T5325 Jason Cooper

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=1393349643-6652-3-git-send-email-andrew@lunn.ch \
    --to=andrew@lunn.ch \
    --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).