Skip to content

Commit 200ee46

Browse files
ruanjinjie-engbroonie
authored andcommitted
regulator: rpi-panel-attiny-regulator: Remove redundant of_match_ptr()
The driver depends on CONFIG_OF, so it is not necessary to use of_match_ptr() here, and __maybe_unused can also be removed. Even for drivers that do not depend on CONFIG_OF, it's almost always better to leave out the of_match_ptr(), since the only thing it can possibly do is to save a few bytes of .text if a driver can be used both with and without it. Signed-off-by: Ruan Jinjie <ruanjinjie@huawei.com> Link: https://lore.kernel.org/r/20230807134127.2380390-1-ruanjinjie@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent c821974 commit 200ee46

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/regulator/rpi-panel-attiny-regulator.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -397,7 +397,7 @@ static struct i2c_driver attiny_regulator_driver = {
397397
.driver = {
398398
.name = "rpi_touchscreen_attiny",
399399
.probe_type = PROBE_PREFER_ASYNCHRONOUS,
400-
.of_match_table = of_match_ptr(attiny_dt_ids),
400+
.of_match_table = attiny_dt_ids,
401401
},
402402
.probe = attiny_i2c_probe,
403403
.remove = attiny_i2c_remove,

0 commit comments

Comments
 (0)