Skip to contentSkip to conversation

acpi/acpi_drivers.h: fix warnings when ACPI_DOCK is not enabled

PATCH In review Arnaud Lacombe 1 participant 2 messages Jul 29, 2011 – Aug 13, 2011

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

PATCH 1/1 acpi/acpi_drivers.h: fix warnings when ACPI_DOCK is not enabled

/src/linux/linux/drivers/ata/libata-acpi.c: In function 'ata_acpi_associate':
/src/linux/linux/drivers/ata/libata-acpi.c:266:11: warning: passing argument 2 of 'register_hotplug_dock_device' discards 'const' qualifier from pointer target type [enabled by default] /src/linux/linux/include/acpi/acpi_drivers.h:146:19: note: expected 'struct acpi_dock_ops *' but argument is of type 'const struct acpi_dock_ops *' /src/linux/linux/drivers/ata/libata-acpi.c:275:11: warning: passing argument 2 of 'register_hotplug_dock_device' discards 'const' qualifier from pointer target type [enabled by default] /src/linux/linux/include/acpi/acpi_drivers.h:146:19: note: expected 'struct acpi_dock_ops *' but argument is of type 'const struct acpi_dock_ops *'

Cc Vasiliy Kulikov <[email protected]>
Cc Jeff Garzik <[email protected]>
Cc Len Brown <[email protected]>
---
 include/acpi/acpi_drivers.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
include/acpi/acpi_drivers.h +1 -1
index e49c36d..bb145e4 100644
@@ -144,7 +144,7 @@ static inline void unregister_dock_notifier(struct notifier_block *nb)
 {
 }
 static inline int register_hotplug_dock_device(acpi_handle handle,
-					       struct acpi_dock_ops *ops,
+					       const struct acpi_dock_ops *ops,
 					       void *context)
 {
 	return -ENODEV;
Signature · 1 line
1.7.6.153.g78432
#1 lore raw

Hi,

Quoted 6 lines · Arnaud Lacombe

/src/linux/linux/drivers/ata/libata-acpi.c: In function 'ata_acpi_associate':
/src/linux/linux/drivers/ata/libata-acpi.c:266:11: warning: passing argument 2 of 'register_hotplug_dock_device' discards 'const' qualifier from pointer target type [enabled by default] /src/linux/linux/include/acpi/acpi_drivers.h:146:19: note: expected 'struct acpi_dock_ops *' but argument is of type 'const struct acpi_dock_ops *' /src/linux/linux/drivers/ata/libata-acpi.c:275:11: warning: passing argument 2 of 'register_hotplug_dock_device' discards 'const' qualifier from pointer target type [enabled by default] /src/linux/linux/include/acpi/acpi_drivers.h:146:19: note: expected 'struct acpi_dock_ops *' but argument is of type 'const struct acpi_dock_ops *'

ping ? next-20110811 is still bad.

- Arnaud

Quoted 25 lines
Cc Vasiliy Kulikov <[email protected]>
Cc Jeff Garzik <[email protected]>
Cc Len Brown <[email protected]>

---
 include/acpi/acpi_drivers.h |    2 +-

 1 files changed, 1 insertions(+), 1 deletions(-)
include/acpi/acpi_drivers.h +1 -2
index e49c36d..bb145e4 100644
@@ -144,7 +144,7 @@ static inline void unregister_dock_notifier(struct notifier_block *nb)
  {
  }
  static inline int register_hotplug_dock_device(acpi_handle handle,
-                                              struct acpi_dock_ops *ops,
+                                              const struct acpi_dock_ops *ops,
                                               void *context)
  {
        return -ENODEV;
--

1.7.6.153.g78432