提交 3b10db23 编写于 作者: O Octavian Purdila 提交者: Wolfram Sang

i2c: dln2: set the device tree node of the adapter

This patch makes sure the platform device tree node is inherited by
the adapter device. This allows the DLN2 bus to work with i2c devices
defined in the device tree.
Signed-off-by: NOctavian Purdila <octavian.purdila@intel.com>
Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
上级 d9e1f441
......@@ -210,6 +210,7 @@ static int dln2_i2c_probe(struct platform_device *pdev)
dln2->adapter.algo = &dln2_i2c_usb_algorithm;
dln2->adapter.quirks = &dln2_i2c_quirks;
dln2->adapter.dev.parent = dev;
dln2->adapter.dev.of_node = dev->of_node;
i2c_set_adapdata(&dln2->adapter, dln2);
snprintf(dln2->adapter.name, sizeof(dln2->adapter.name), "%s-%s-%d",
"dln2-i2c", dev_name(pdev->dev.parent), dln2->port);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册