mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-06-06 22:58:29 +00:00
hwmon: (scpi) Fix module autoload
If the driver is built as a module, autoload won't work because the module
alias information is not filled. So user-space can't match the registered
device with the corresponding module.
Export the module alias information using the MODULE_DEVICE_TABLE() macro.
Before this patch:
$ modinfo drivers/hwmon/scpi-hwmon.ko | grep alias
$
After this patch:
$ modinfo drivers/hwmon/scpi-hwmon.ko | grep alias
alias: of:N*T*Carm,scpi-sensorsC*
alias: of:N*T*Carm,scpi-sensors
Signed-off-by: Javier Martinez Canillas <javier@osg.samsung.com>
Fixes: ea98b29a05
("hwmon: Support sensors exported via ARM SCP interface")
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
This commit is contained in:
parent
e5517c2a5a
commit
13edb767aa
1 changed files with 1 additions and 0 deletions
|
@ -251,6 +251,7 @@ static const struct of_device_id scpi_of_match[] = {
|
||||||
{.compatible = "arm,scpi-sensors"},
|
{.compatible = "arm,scpi-sensors"},
|
||||||
{},
|
{},
|
||||||
};
|
};
|
||||||
|
MODULE_DEVICE_TABLE(of, scpi_of_match);
|
||||||
|
|
||||||
static struct platform_driver scpi_hwmon_platdrv = {
|
static struct platform_driver scpi_hwmon_platdrv = {
|
||||||
.driver = {
|
.driver = {
|
||||||
|
|
Loading…
Add table
Reference in a new issue