summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiyush Malgujar <pmalgujar@marvell.com>2022-05-11 06:36:59 -0700
committerWolfram Sang <wsa@kernel.org>2022-05-21 13:41:28 +0200
commit03a35bc856ddc09f2cc1f4701adecfbf3b464cb3 (patch)
tree22e62d57e34ee0ad249b49d98c58b2d95137ca7a
parent17a0f3acdc6ec8b89ad40f6e22165a4beee25663 (diff)
drivers: i2c: thunderx: Allow driver to work with ACPI defined TWSI controllers
Due to i2c->adap.dev.fwnode not being set, ACPI_COMPANION() wasn't properly found for TWSI controllers. Signed-off-by: Szymon Balcerak <sbalcerak@marvell.com> Signed-off-by: Piyush Malgujar <pmalgujar@marvell.com> Signed-off-by: Wolfram Sang <wsa@kernel.org>
-rw-r--r--drivers/i2c/busses/i2c-thunderx-pcidrv.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/i2c/busses/i2c-thunderx-pcidrv.c b/drivers/i2c/busses/i2c-thunderx-pcidrv.c
index 12c90aa0900e..a77cd86fe75e 100644
--- a/drivers/i2c/busses/i2c-thunderx-pcidrv.c
+++ b/drivers/i2c/busses/i2c-thunderx-pcidrv.c
@@ -213,6 +213,7 @@ static int thunder_i2c_probe_pci(struct pci_dev *pdev,
i2c->adap.bus_recovery_info = &octeon_i2c_recovery_info;
i2c->adap.dev.parent = dev;
i2c->adap.dev.of_node = pdev->dev.of_node;
+ i2c->adap.dev.fwnode = dev->fwnode;
snprintf(i2c->adap.name, sizeof(i2c->adap.name),
"Cavium ThunderX i2c adapter at %s", dev_name(dev));
i2c_set_adapdata(&i2c->adap, i2c);