summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorArend van Spriel <aspriel@gmail.com>2018-04-08 23:57:07 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-19 09:48:32 +0200
commited4564babeeee4fb19fe4ec0beabe29754e380f9 (patch)
treea75c9fe5f002d598a13e759ead3972ec91ebe0eb /include
parent60cc43fc888428bb2f18f08997432d426a243338 (diff)
downloadlinux-ed4564babeeee4fb19fe4ec0beabe29754e380f9.tar.bz2
drivers: change struct device_driver::coredump() return type to void
Upon submitting a patch for mwifiex [1] it was discussed whether this callback function could fail. To keep things simple there is no need for the error code so the driver can do the task synchronous or not without worries. Currently the device driver core already ignores the return value so changing it to void. [1] https://patchwork.kernel.org/patch/10231933/ Signed-off-by: Arend van Spriel <aspriel@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include')
-rw-r--r--include/linux/device.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/include/linux/device.h b/include/linux/device.h
index 0059b99e1f25..477956990f5e 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -256,7 +256,9 @@ enum probe_type {
* automatically.
* @pm: Power management operations of the device which matched
* this driver.
- * @coredump: Called through sysfs to initiate a device coredump.
+ * @coredump: Called when sysfs entry is written to. The device driver
+ * is expected to call the dev_coredump API resulting in a
+ * uevent.
* @p: Driver core's private data, no one other than the driver
* core can touch this.
*
@@ -288,7 +290,7 @@ struct device_driver {
const struct attribute_group **groups;
const struct dev_pm_ops *pm;
- int (*coredump) (struct device *dev);
+ void (*coredump) (struct device *dev);
struct driver_private *p;
};