[PATCH] i2c: Convert i2c-mpc.c to use i2c_add_prenumbered_adapter().
Scott Wood
scottwood at freescale.com
Fri May 18 00:59:58 EST 2007
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
More information about the Linuxppc-dev
mailing list