the of_node will auto-publish devices which are added to the device
tree.

Cc: [email protected]
Signed-off-by: Sebastian Andrzej Siewior <[email protected]>
Signed-off-by: Dirk Brandewie <[email protected]>
---
 drivers/i2c/busses/i2c-pxa.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/drivers/i2c/busses/i2c-pxa.c b/drivers/i2c/busses/i2c-pxa.c
index 1a48470..dd6ed77 100644
--- a/drivers/i2c/busses/i2c-pxa.c
+++ b/drivers/i2c/busses/i2c-pxa.c
@@ -1083,6 +1083,9 @@ static int i2c_pxa_probe(struct platform_device *dev)
 
        i2c->adap.algo_data = i2c;
        i2c->adap.dev.parent = &dev->dev;
+#ifdef CONFIG_OF
+       i2c->adap.dev.of_node = dev->dev.of_node;
+#endif
 
        ret = i2c_add_numbered_adapter(&i2c->adap);
        if (ret < 0) {
-- 
1.7.3.2

--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to