]> git.baikalelectronics.ru Git - kernel.git/commit
hwmon: (tmp401) Add OF device ID table
authorCamel Guo <camel.guo@axis.com>
Tue, 3 May 2022 11:43:33 +0000 (13:43 +0200)
committerGuenter Roeck <linux@roeck-us.net>
Tue, 3 May 2022 13:44:25 +0000 (06:44 -0700)
commit2e938da42c3dd3f4935f10d50b6097c0bc026a1d
tree993e3fb0665e4801cf1322fe15e8eb697406096b
parentdf628ec2e08f05af065ab044867a0f9dc0e839df
hwmon: (tmp401) Add OF device ID table

This driver doesn't have of_match_table. This makes the kernel module
tmp401.ko lack alias patterns (e.g: of:N*T*Cti,tmp411) to match DT node
of the supported devices hence this kernel module will not be
automatically loaded.

After adding of_match_table to this driver, the folllowing alias will be
added into tmp401.ko.
$ modinfo drivers/hwmon/tmp401.ko
filename: drivers/hwmon/tmp401.ko
......
author:         Hans de Goede <hdegoede@redhat.com>
alias:          of:N*T*Cti,tmp435C*
alias:          of:N*T*Cti,tmp435
alias:          of:N*T*Cti,tmp432C*
alias:          of:N*T*Cti,tmp432
alias:          of:N*T*Cti,tmp431C*
alias:          of:N*T*Cti,tmp431
alias:          of:N*T*Cti,tmp411C*
alias:          of:N*T*Cti,tmp411
alias:          of:N*T*Cti,tmp401C*
alias:          of:N*T*Cti,tmp401
......

Fixes: 8a1a57e8dcd0 ("i2c: core: report OF style module alias for devices registered via OF")
Signed-off-by: Camel Guo <camel.guo@axis.com>
Link: https://lore.kernel.org/r/20220503114333.456476-1-camel.guo@axis.com
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/tmp401.c