Skip to content

Commit 8fefb31

Browse files
andy-shevojeda
authored andcommitted
auxdisplay: lcd2s: Switch to i2c ->probe_new()
The deprecated i2c ->probe() functionality doesn't work with OF compatible strings, as it only checks for the i2c device id. While it's not a problem right now, it would still bring a better code. Switch to the new way of probing. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Miguel Ojeda <ojeda@kernel.org>
1 parent f15c3de commit 8fefb31

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/auxdisplay/lcd2s.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -287,8 +287,7 @@ static const struct charlcd_ops lcd2s_ops = {
287287
.redefine_char = lcd2s_redefine_char,
288288
};
289289

290-
static int lcd2s_i2c_probe(struct i2c_client *i2c,
291-
const struct i2c_device_id *id)
290+
static int lcd2s_i2c_probe(struct i2c_client *i2c)
292291
{
293292
struct charlcd *lcd;
294293
struct lcd2s_data *lcd2s;
@@ -367,7 +366,7 @@ static struct i2c_driver lcd2s_i2c_driver = {
367366
.name = "lcd2s",
368367
.of_match_table = lcd2s_of_table,
369368
},
370-
.probe = lcd2s_i2c_probe,
369+
.probe_new = lcd2s_i2c_probe,
371370
.remove = lcd2s_i2c_remove,
372371
.id_table = lcd2s_i2c_id,
373372
};

0 commit comments

Comments
 (0)