Skip to contentSkip to conversation

eeepc-wmi: fix compiler warning

PATCH Applied Dmitry Torokhov 4 participants 4 messages Nov 3, 2010 – Nov 24, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 eeepc-wmi: fix compiler warning

This fixes the following:

CC [M] drivers/platform/x86/eeepc-wmi.o
drivers/platform/x86/eeepc-wmi.c:322: warning: initialization from incompatible pointer type

---

 drivers/platform/x86/eeepc-wmi.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/platform/x86/eeepc-wmi.c +2 -2
index 462ceab..0d50fbb 100644
@@ -298,8 +298,8 @@ static void eeepc_wmi_notify(u32 value, void *context)
 	kfree(obj);
 }
 
-static int store_cpufv(struct device *dev, struct device_attribute *attr,
-		       const char *buf, size_t count)
+static ssize_t store_cpufv(struct device *dev, struct device_attribute *attr,
+			   const char *buf, size_t count)
 {
 	int value;
 	struct acpi_buffer input = { (acpi_size)sizeof(value), &value };
Reviewed-by on v1 1/1
#1 lore raw
Quoted 18 lines · Dmitry Torokhov

This fixes the following:

 CC [M]  drivers/platform/x86/eeepc-wmi.o drivers/platform/x86/eeepc-wmi.c:322: warning: initialization from incompatible pointer type

---

 drivers/platform/x86/eeepc-wmi.c |    4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/platform/x86/eeepc-wmi.c +0 -0
index 462ceab..0d50fbb 100644
@@ -298,8 +298,8 @@ static void eeepc_wmi_notify(u32 value, void *context)
        kfree(obj);

drivers/platform/x86/eeepc-wmi.c static void eeepc_wmi_notify(u32 value, void *context)

Quoted 10 lines
drivers/platform/x86/eeepc-wmi.c +2 -3
  }
 
-static int store_cpufv(struct device *dev, struct device_attribute *attr,
-                      const char *buf, size_t count)
+static ssize_t store_cpufv(struct device *dev, struct device_attribute *attr,
+                          const char *buf, size_t count)
  {
        int value;
        struct acpi_buffer input = { (acpi_size)sizeof(value), &value };
--

Opps. Sorry, I missed that warning. ssize_t is obviously correct return value.

maintainer
#2 lore raw
Quoted 33 lines · Chris Bagwell
Quoted 18 lines · Dmitry Torokhov

This fixes the following:

 CC [M]  drivers/platform/x86/eeepc-wmi.o drivers/platform/x86/eeepc-wmi.c:322: warning: initialization from incompatible pointer type

---

 drivers/platform/x86/eeepc-wmi.c |    4 ++--

 1 files changed, 2 insertions(+), 2 deletions(-)
drivers/platform/x86/eeepc-wmi.c +0 -0
index 462ceab..0d50fbb 100644
@@ -298,8 +298,8 @@ static void eeepc_wmi_notify(u32 value, void *context)
        kfree(obj);

drivers/platform/x86/eeepc-wmi.c static void eeepc_wmi_notify(u32 value, void *context)

Quoted 10 lines
drivers/platform/x86/eeepc-wmi.c +2 -3
  }
 
-static int store_cpufv(struct device *dev, struct device_attribute *attr,
-                      const char *buf, size_t count)
+static ssize_t store_cpufv(struct device *dev, struct device_attribute *attr,
+                          const char *buf, size_t count)
  {
        int value;
        struct acpi_buffer input = { (acpi_size)sizeof(value), &value };
--

Opps.  Sorry, I missed that warning.  ssize_t is obviously correct return value.

Quoted 6 lines

--
To unsubscribe from this list: send the line "unsubscribe platform-driver-x86" in the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Just queued the same patch on my repo, I should have read the list first.

Matthew can you queue this one for next batch ?
Thanks,

Signature · 2 lines
Corentin Chary
http://xf.iksaif.net