diff options
author | Uwe Kleine-König <uwe@kleine-koenig.org> | 2021-02-05 23:28:42 +0100 |
---|---|---|
committer | Dan Williams <dan.j.williams@intel.com> | 2021-02-16 19:45:13 -0800 |
commit | 0d519e0d52ee7c532d4018b90cd0b042d374c06d (patch) | |
tree | 695200849ef56292e0afc2aa804a87ba82186cde /drivers/dax/bus.c | |
parent | c80b53204d6ee8f70e5f4e846bc0e62dda64aee0 (diff) | |
download | linux-0d519e0d52ee7c532d4018b90cd0b042d374c06d.tar.bz2 |
dax-device: Make remove callback return void
The driver core ignores the return value of struct bus_type::remove()
because there is only little that can be done. To simplify the quest to
make this function return void, let struct dax_device_driver::remove()
return void, too. All users already unconditionally return 0, this commit
makes it obvious that returning an error code isn't intended.
Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Link: https://lore.kernel.org/r/20210205222842.34896-6-uwe@kleine-koenig.org
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
Diffstat (limited to 'drivers/dax/bus.c')
-rw-r--r-- | drivers/dax/bus.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/dax/bus.c b/drivers/dax/bus.c index d2419e88073a..452e85ae87a8 100644 --- a/drivers/dax/bus.c +++ b/drivers/dax/bus.c @@ -178,12 +178,11 @@ static int dax_bus_remove(struct device *dev) { struct dax_device_driver *dax_drv = to_dax_drv(dev->driver); struct dev_dax *dev_dax = to_dev_dax(dev); - int ret = 0; if (dax_drv->remove) - ret = dax_drv->remove(dev_dax); + dax_drv->remove(dev_dax); - return ret; + return 0; } static struct bus_type dax_bus_type = { |