Skip to content

Commit 01d9387

Browse files
Uwe Kleine-Königwsakernel
authored andcommitted
serial: sc16is7xx: Convert to i2c's .probe_new()
.probe_new() doesn't get the i2c_device_id * parameter, so determine that explicitly in the probe function. Reviewed-by: Greg Kroah-Hartman <[email protected]> Link: https://lore.kernel.org/lkml/[email protected] Signed-off-by: Uwe Kleine-König <[email protected]> Signed-off-by: Wolfram Sang <[email protected]>
1 parent 0b79d5d commit 01d9387

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

drivers/tty/serial/sc16is7xx.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1666,9 +1666,9 @@ MODULE_ALIAS("spi:sc16is7xx");
16661666
#endif
16671667

16681668
#ifdef CONFIG_SERIAL_SC16IS7XX_I2C
1669-
static int sc16is7xx_i2c_probe(struct i2c_client *i2c,
1670-
const struct i2c_device_id *id)
1669+
static int sc16is7xx_i2c_probe(struct i2c_client *i2c)
16711670
{
1671+
const struct i2c_device_id *id = i2c_client_get_device_id(i2c);
16721672
const struct sc16is7xx_devtype *devtype;
16731673
struct regmap *regmap;
16741674

@@ -1709,7 +1709,7 @@ static struct i2c_driver sc16is7xx_i2c_uart_driver = {
17091709
.name = SC16IS7XX_NAME,
17101710
.of_match_table = sc16is7xx_dt_ids,
17111711
},
1712-
.probe = sc16is7xx_i2c_probe,
1712+
.probe_new = sc16is7xx_i2c_probe,
17131713
.remove = sc16is7xx_i2c_remove,
17141714
.id_table = sc16is7xx_i2c_id_table,
17151715
};

0 commit comments

Comments
 (0)