diff mbox

[10/15] platform/x86: wmi: make device_type const

Message ID 1503130946-2854-11-git-send-email-bhumirks@gmail.com (mailing list archive)
State Changes Requested, archived
Delegated to: Andy Shevchenko
Headers show

Commit Message

Bhumika Goyal Aug. 19, 2017, 8:22 a.m. UTC
Make these const as they are only stored in the type field of a device
structure, which is const.
Done using Coccinelle.

Signed-off-by: Bhumika Goyal <bhumirks@gmail.com>
---
 drivers/platform/x86/wmi.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Comments

Andy Shevchenko Aug. 30, 2017, 7:23 p.m. UTC | #1
On Sat, Aug 19, 2017 at 11:22 AM, Bhumika Goyal <bhumirks@gmail.com> wrote:
> Make these const as they are only stored in the type field of a device
> structure, which is const.
> Done using Coccinelle.
>

Please, stop spamming so many people and MLs with no relation to the subsystem!

Now, resend with reduced Cc (see headers) and don't forget to include
Andy Lutomirski
Bhumika Goyal Aug. 31, 2017, 5:49 a.m. UTC | #2
On Thu, Aug 31, 2017 at 12:53 AM, Andy Shevchenko
<andy.shevchenko@gmail.com> wrote:
> On Sat, Aug 19, 2017 at 11:22 AM, Bhumika Goyal <bhumirks@gmail.com> wrote:
>> Make these const as they are only stored in the type field of a device
>> structure, which is const.
>> Done using Coccinelle.
>>
>
> Please, stop spamming so many people and MLs with no relation to the subsystem!
>

Sorry, for the inconvenience.

> Now, resend with reduced Cc (see headers) and don't forget to include
> Andy Lutomirski
>

Yes.

Thanks,
Bhumika

>
> --
> With Best Regards,
> Andy Shevchenko
diff mbox

Patch

diff --git a/drivers/platform/x86/wmi.c b/drivers/platform/x86/wmi.c
index e32ba57..a37c253 100644
--- a/drivers/platform/x86/wmi.c
+++ b/drivers/platform/x86/wmi.c
@@ -810,19 +810,19 @@  static int wmi_dev_remove(struct device *dev)
 	.remove = wmi_dev_remove,
 };
 
-static struct device_type wmi_type_event = {
+static const struct device_type wmi_type_event = {
 	.name = "event",
 	.groups = wmi_event_groups,
 	.release = wmi_dev_release,
 };
 
-static struct device_type wmi_type_method = {
+static const struct device_type wmi_type_method = {
 	.name = "method",
 	.groups = wmi_method_groups,
 	.release = wmi_dev_release,
 };
 
-static struct device_type wmi_type_data = {
+static const struct device_type wmi_type_data = {
 	.name = "data",
 	.groups = wmi_data_groups,
 	.release = wmi_dev_release,