Skip to content

Commit d9deb28

Browse files
Aniketalexandrebelloni
authored andcommitted
i3c: dw: Remove ibi_capable property
Since DW I3C IP master role always supports IBI, we don't need to keep two variants of master ops and select one using this property. Hence remove the code. Signed-off-by: Aniket <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Alexandre Belloni <[email protected]>
1 parent 64bf145 commit d9deb28

File tree

3 files changed

+2
-23
lines changed

3 files changed

+2
-23
lines changed

drivers/i3c/master/ast2600-i3c-master.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,6 @@ static int ast2600_i3c_probe(struct platform_device *pdev)
156156
i3c->sda_pullup);
157157

158158
i3c->dw.platform_ops = &ast2600_i3c_ops;
159-
i3c->dw.ibi_capable = true;
160159
return dw_i3c_common_probe(&i3c->dw, pdev);
161160
}
162161

drivers/i3c/master/dw-i3c-master.c

Lines changed: 2 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1404,21 +1404,6 @@ static const struct i3c_master_controller_ops dw_mipi_i3c_ops = {
14041404
.attach_i2c_dev = dw_i3c_master_attach_i2c_dev,
14051405
.detach_i2c_dev = dw_i3c_master_detach_i2c_dev,
14061406
.i2c_xfers = dw_i3c_master_i2c_xfers,
1407-
};
1408-
1409-
static const struct i3c_master_controller_ops dw_mipi_i3c_ibi_ops = {
1410-
.bus_init = dw_i3c_master_bus_init,
1411-
.bus_cleanup = dw_i3c_master_bus_cleanup,
1412-
.attach_i3c_dev = dw_i3c_master_attach_i3c_dev,
1413-
.reattach_i3c_dev = dw_i3c_master_reattach_i3c_dev,
1414-
.detach_i3c_dev = dw_i3c_master_detach_i3c_dev,
1415-
.do_daa = dw_i3c_master_daa,
1416-
.supports_ccc_cmd = dw_i3c_master_supports_ccc_cmd,
1417-
.send_ccc_cmd = dw_i3c_master_send_ccc_cmd,
1418-
.priv_xfers = dw_i3c_master_priv_xfers,
1419-
.attach_i2c_dev = dw_i3c_master_attach_i2c_dev,
1420-
.detach_i2c_dev = dw_i3c_master_detach_i2c_dev,
1421-
.i2c_xfers = dw_i3c_master_i2c_xfers,
14221407
.request_ibi = dw_i3c_master_request_ibi,
14231408
.free_ibi = dw_i3c_master_free_ibi,
14241409
.enable_ibi = dw_i3c_master_enable_ibi,
@@ -1456,7 +1441,6 @@ static void dw_i3c_hj_work(struct work_struct *work)
14561441
int dw_i3c_common_probe(struct dw_i3c_master *master,
14571442
struct platform_device *pdev)
14581443
{
1459-
const struct i3c_master_controller_ops *ops;
14601444
int ret, irq;
14611445

14621446
if (!master->platform_ops)
@@ -1506,12 +1490,9 @@ int dw_i3c_common_probe(struct dw_i3c_master *master,
15061490
master->maxdevs = ret >> 16;
15071491
master->free_pos = GENMASK(master->maxdevs - 1, 0);
15081492

1509-
ops = &dw_mipi_i3c_ops;
1510-
if (master->ibi_capable)
1511-
ops = &dw_mipi_i3c_ibi_ops;
1512-
15131493
INIT_WORK(&master->hj_work, dw_i3c_hj_work);
1514-
ret = i3c_master_register(&master->base, &pdev->dev, ops, false);
1494+
ret = i3c_master_register(&master->base, &pdev->dev,
1495+
&dw_mipi_i3c_ops, false);
15151496
if (ret)
15161497
goto err_assert_rst;
15171498

drivers/i3c/master/dw-i3c-master.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,6 @@ struct dw_i3c_master {
3838
struct clk *core_clk;
3939
char version[5];
4040
char type[5];
41-
bool ibi_capable;
4241
u32 sir_rej_mask;
4342
/*
4443
* Per-device hardware data, used to manage the device address table

0 commit comments

Comments
 (0)