linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c: Move i2c-mpc.c from i2c_add_adapter() to i2c_register_adapter().
@ 2006-12-07 17:30 Scott Wood
  0 siblings, 0 replies; only message in thread
From: Scott Wood @ 2006-12-07 17:30 UTC (permalink / raw)
  To: i2c; +Cc: linuxppc-dev

Call i2c_register_adapter() in i2c-mpc.c so that scan_static_board_info()
will pick it up.

Signed-off-by: Scott Wood <scottwood@freescale.com>
---
This patch depends on David Brownell's patchset at
http://lists.lm-sensors.org/pipermail/i2c/2006-November/000516.html

 drivers/i2c/busses/i2c-mpc.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index 29891b6..aefbca7 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -330,7 +330,8 @@ static int fsl_i2c_probe(struct platform
 	i2c->adap = mpc_ops;
 	i2c_set_adapdata(&i2c->adap, i2c);
 	i2c->adap.class_dev.dev = &pdev->dev;
-	if ((result = i2c_add_adapter(&i2c->adap)) < 0) {
+	i2c->adap.nr = pdev->id;
+	if ((result = i2c_register_adapter(&i2c->adap)) < 0) {
 		printk(KERN_ERR "i2c-mpc - failed to add adapter\n");
 		goto fail_add;
 	}
-- 
1.4.2.3

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2006-12-07 17:35 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-07 17:30 [PATCH] i2c: Move i2c-mpc.c from i2c_add_adapter() to i2c_register_adapter() Scott Wood

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