ACPI: fix acpi_debugfs_init prototype
authorNicolas Iooss <nicolas.iooss_linux@m4x.org>
Sat, 1 Aug 2015 13:32:17 +0000 (21:32 +0800)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Fri, 7 Aug 2015 00:55:18 +0000 (02:55 +0200)
acpi_debugfs_init function is declared with return type int in
drivers/acpi/internal.h when CONFIG_DEBUG_FS is enabled, but its
definition in drivers/acpi/debugfs.c has return type void. This is due
to commit aecad432fd68 ("ACPI: Cleanup custom_method debug stuff"),
which changed the return type from int to void without updating the
declaration.

Fix this inconsistency by updating acpi_debugfs_init prototype.  While
at it, include internal.h in debugfs.c so that the compiler can check
that the declaration and definition remain compatible.

Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@m4x.org>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/acpi/debugfs.c
drivers/acpi/internal.h

index 6b1919f6bd8212248f8a7399c21f73b1303a254e..68bb305b977f9ce481be8d3e95f90ca67922421b 100644 (file)
@@ -7,6 +7,8 @@
 #include <linux/debugfs.h>
 #include <linux/acpi.h>
 
+#include "internal.h"
+
 #define _COMPONENT             ACPI_SYSTEM_COMPONENT
 ACPI_MODULE_NAME("debugfs");
 
index 8c71cb8335c0c210be29f11333784a5100b4b8d2..daf0974d863cfc853e56b205afea9d904814cc8e 100644 (file)
@@ -67,7 +67,7 @@ void acpi_scan_hotplug_enabled(struct acpi_hotplug_profile *hotplug, bool val);
 
 #ifdef CONFIG_DEBUG_FS
 extern struct dentry *acpi_debugfs_dir;
-int acpi_debugfs_init(void);
+void acpi_debugfs_init(void);
 #else
 static inline void acpi_debugfs_init(void) { return; }
 #endif
This page took 0.027472 seconds and 5 git commands to generate.