From: "Thomas Weißschuh" <thomas@t-8ch.de>
To: Denis Pauk <pauk.denis@gmail.com>
Cc: eugene.shalygin@gmail.com, andy.shevchenko@gmail.com,
Ed Brindley <kernel@maidavale.org>,
Jean Delvare <jdelvare@suse.com>,
Guenter Roeck <linux@roeck-us.net>,
Jonathan Corbet <corbet@lwn.net>,
linux-hwmon@vger.kernel.org, linux-doc@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 2/2] hwmon: (asus_wmi_sensors) Support X370 Asus WMI.
Date: Sun, 10 Oct 2021 12:20:52 +0200 [thread overview]
Message-ID: <0a037ce5-87bb-4aad-a30a-d954ff0910a7@t-8ch.de> (raw)
In-Reply-To: <20211010095216.25115-3-pauk.denis@gmail.com>
Hi,
for WMI drivers the list platform-driver-x86@vger.kernel.org should probably be
on CC too.
Also all other WMI drivers, even for hwmon stuff are located in
drivers/platform/x86 so it may be better to put it there, too.
One comment inline.
On 2021-10-10T12:52+0300, Denis Pauk wrote:
> +static struct platform_driver asus_wmi_sensors_platform_driver = {
> + .driver = {
> + .name = "asus-wmi-sensors",
> + },
> + .probe = asus_wmi_probe,
> +};
> +
> +static struct platform_device *sensors_pdev;
> +
> +static int __init asus_wmi_init(void)
> +{
> + if (!dmi_check_system(asus_wmi_dmi_table))
> + return -ENODEV;
> +
> + sensors_pdev = platform_create_bundle(&asus_wmi_sensors_platform_driver,
> + asus_wmi_probe,
> + NULL, 0,
> + NULL, 0);
> +
> + return PTR_ERR_OR_ZERO(sensors_pdev);
> +}
> +module_init(asus_wmi_init);
> +
> +static void __exit asus_wmi_exit(void)
> +{
> + platform_device_unregister(sensors_pdev);
> + platform_driver_unregister(&asus_wmi_sensors_platform_driver);
> +}
> +module_exit(asus_wmi_exit);
This should bind to the WMI bus instead of being a platform device.
See drivers/platform/x86/gigabyte-wmi.c
(Some goes also for the other driver)
Thomas
next prev parent reply other threads:[~2021-10-10 10:21 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-10 9:52 [PATCH v3 0/2] Update ASUS WMI supported boards Denis Pauk
2021-10-10 9:52 ` [PATCH v3 1/2] hwmon: (asus_wmi_ec_sensors) Support B550 Asus WMI Denis Pauk
2021-10-10 9:52 ` [PATCH v3 2/2] hwmon: (asus_wmi_sensors) Support X370 " Denis Pauk
2021-10-10 10:20 ` Thomas Weißschuh [this message]
2021-10-10 13:38 ` Guenter Roeck
2021-10-10 14:10 ` Thomas Weißschuh
2021-10-10 14:56 ` Guenter Roeck
2021-10-10 15:28 ` Thomas Weißschuh
2021-10-10 16:21 ` Guenter Roeck
2021-10-10 13:54 ` [PATCH v3 0/2] Update ASUS WMI supported boards Pali Rohár
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=0a037ce5-87bb-4aad-a30a-d954ff0910a7@t-8ch.de \
--to=thomas@t-8ch.de \
--cc=andy.shevchenko@gmail.com \
--cc=corbet@lwn.net \
--cc=eugene.shalygin@gmail.com \
--cc=jdelvare@suse.com \
--cc=kernel@maidavale.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-hwmon@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=pauk.denis@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox