devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] of/i2c: support more interrupt specifiers
@ 2012-11-21  8:58 Bongkyu Kim
  2012-11-21 13:41 ` Rob Herring
  0 siblings, 1 reply; 5+ messages in thread
From: Bongkyu Kim @ 2012-11-21  8:58 UTC (permalink / raw)
  To: grant.likely, rob.herring; +Cc: devicetree-discuss, linux-kernel, Bongkyu Kim

This patch supports more interrupt specifiers for i2c client.

Signed-off-by: Bongkyu Kim <bongkyu.kim@lge.com>
---
 drivers/of/of_i2c.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/of/of_i2c.c b/drivers/of/of_i2c.c
index 3550f3b..c6d9b7e 100644
--- a/drivers/of/of_i2c.c
+++ b/drivers/of/of_i2c.c
@@ -34,6 +34,7 @@ void of_i2c_register_devices(struct i2c_adapter *adap)
 		struct dev_archdata dev_ad = {};
 		const __be32 *addr;
 		int len;
+		int nr = 0;
 
 		dev_dbg(&adap->dev, "of_i2c: register %s\n", node->full_name);
 
@@ -57,7 +58,9 @@ void of_i2c_register_devices(struct i2c_adapter *adap)
 			continue;
 		}
 
-		info.irq = irq_of_parse_and_map(node, 0);
+		info.irq = irq_of_parse_and_map(node, nr++);
+		while (irq_of_parse_and_map(node, nr))
+			nr++;
 		info.of_node = of_node_get(node);
 		info.archdata = &dev_ad;
 
-- 
1.8.0

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

end of thread, other threads:[~2012-11-26 14:08 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-11-21  8:58 [PATCH] of/i2c: support more interrupt specifiers Bongkyu Kim
2012-11-21 13:41 ` Rob Herring
     [not found]   ` <50ACD9F2.40207-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-11-22  5:50     ` 김봉규
2012-11-26  5:11   ` Bongkyu Kim
2012-11-26 14:08     ` Grant Likely

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).