lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <4b402929-f637-426f-8d18-634a29b95b42@roeck-us.net>
Date: Sat, 6 Sep 2025 06:28:02 -0700
From: Guenter Roeck <linux@...ck-us.net>
To: Andreas Kemnade <andreas@...nade.info>, jdelvare@...e.com,
 linux-hwmon@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] hwmon: sy7636a: add aliases

On 9/6/25 02:43, Andreas Kemnade wrote:
> Add module aliases via module devicetable to have it autoloaded.
> 
> Signed-off-by: Andreas Kemnade <andreas@...nade.info>
> ---
>   drivers/hwmon/sy7636a-hwmon.c | 8 ++++++++
>   1 file changed, 8 insertions(+)
> 
> diff --git a/drivers/hwmon/sy7636a-hwmon.c b/drivers/hwmon/sy7636a-hwmon.c
> index ed110884786b4..74ee0e756ffdc 100644
> --- a/drivers/hwmon/sy7636a-hwmon.c
> +++ b/drivers/hwmon/sy7636a-hwmon.c
> @@ -12,6 +12,7 @@
>   #include <linux/hwmon.h>
>   #include <linux/init.h>
>   #include <linux/module.h>
> +#include <linux/mod_devicetable.h>
>   #include <linux/platform_device.h>
>   #include <linux/regmap.h>
>   #include <linux/regulator/machine.h>
> @@ -94,11 +95,18 @@ static int sy7636a_sensor_probe(struct platform_device *pdev)
>   	return 0;
>   }
>   
> +static const struct platform_device_id sy7636a_sensor_idtable[] = {
> +	{ "sy7636a-temperature" },
> +	{ },
> +};
> +MODULE_DEVICE_TABLE(platform, sy7636a_sensor_idtable);
> +
>   static struct platform_driver sy7636a_sensor_driver = {
>   	.probe = sy7636a_sensor_probe,
>   	.driver = {
>   		.name = "sy7636a-temperature",
>   	},
> +	.id_table = sy7636a_sensor_idtable,
>   };
>   module_platform_driver(sy7636a_sensor_driver);
>   

I would suggest to just add

MODULE_ALIAS("platform:sy7636a-temperature");

instead.

Guenter


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ