summaryrefslogtreecommitdiffstats
path: root/drivers/i3c/master/i3c-master-cdns.c
diff options
context:
space:
mode:
authorPrzemyslaw Gaj <pgaj@cadence.com>2019-06-22 22:54:59 +0200
committerBoris Brezillon <boris.brezillon@collabora.com>2019-08-11 10:48:28 +0200
commitb1ac3a4b9aa2f68d498824f1235788e67b51b486 (patch)
tree2c2642336eaf927456d1fc0582c3cf35f94d8b30 /drivers/i3c/master/i3c-master-cdns.c
parenti3c: master: cdns: Use for_each_set_bit() (diff)
downloadlinux-b1ac3a4b9aa2f68d498824f1235788e67b51b486.tar.xz
linux-b1ac3a4b9aa2f68d498824f1235788e67b51b486.zip
i3c: add addr and lvr to i2c_dev_desc structure
I need to store address and lvr value for I2C devices without static definition in DT. This allows secondary master to transmit DEFSLVS command properly. Main changes between v4 and v5: - Change in defslvs to use addr and lvr from i2c_dev_desc structure - Change in CDNS and DW drivers to use addr and lvr from i2c_dev_desc structure Signed-off-by: Przemyslaw Gaj <pgaj@cadence.com> Signed-off-by: Boris Brezillon <boris.brezillon@collabora.com>
Diffstat (limited to 'drivers/i3c/master/i3c-master-cdns.c')
-rw-r--r--drivers/i3c/master/i3c-master-cdns.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/i3c/master/i3c-master-cdns.c b/drivers/i3c/master/i3c-master-cdns.c
index c8adf1eb7e1e..10db0bf0655a 100644
--- a/drivers/i3c/master/i3c-master-cdns.c
+++ b/drivers/i3c/master/i3c-master-cdns.c
@@ -1003,9 +1003,9 @@ static int cdns_i3c_master_attach_i2c_dev(struct i2c_dev_desc *dev)
master->free_rr_slots &= ~BIT(slot);
i2c_dev_set_master_data(dev, data);
- writel(prepare_rr0_dev_address(dev->boardinfo->base.addr),
+ writel(prepare_rr0_dev_address(dev->addr),
master->regs + DEV_ID_RR0(data->id));
- writel(dev->boardinfo->lvr, master->regs + DEV_ID_RR2(data->id));
+ writel(dev->lvr, master->regs + DEV_ID_RR2(data->id));
writel(readl(master->regs + DEVS_CTRL) |
DEVS_CTRL_DEV_ACTIVE(data->id),
master->regs + DEVS_CTRL);