DORMANTno replies

[PATCH] i2c: Convert i2c-mpc.c to use i2c_add_prenumbered_adapter().

From: Scott Wood <hidden>
Date: 2007-05-17 15:07:45
Subsystem: freescale mpc i2c driver, i2c subsystem, i2c subsystem host drivers, the rest · Maintainers: Chris Packham, Andi Shyti, Linus Torvalds

This allows platform code to preregister devices on the i2c bus.
---
 drivers/i2c/busses/i2c-mpc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/i2c/busses/i2c-mpc.c b/drivers/i2c/busses/i2c-mpc.c
index c6b6898..b7870de 100644
--- a/drivers/i2c/busses/i2c-mpc.c
+++ b/drivers/i2c/busses/i2c-mpc.c
@@ -329,7 +329,7 @@ static int fsl_i2c_probe(struct platform_device *pdev)
 	i2c->adap = mpc_ops;
 	i2c_set_adapdata(&i2c->adap, i2c);
 	i2c->adap.dev.parent = &pdev->dev;
-	if ((result = i2c_add_adapter(&i2c->adap)) < 0) {
+	if ((result = i2c_add_prenumbered_adapter(&i2c->adap, pdev->id)) < 0) {
 		printk(KERN_ERR "i2c-mpc - failed to add adapter\n");
 		goto fail_add;
 	}
-- 
1.5.0.3
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help