diff options
-rw-r--r-- | drivers/spmi/spmi.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/spmi/spmi.c b/drivers/spmi/spmi.c index c16b60f645a4..fd3ff6079b15 100644 --- a/drivers/spmi/spmi.c +++ b/drivers/spmi/spmi.c @@ -545,13 +545,10 @@ static int spmi_ctrl_remove_device(struct device *dev, void *data) */ void spmi_controller_remove(struct spmi_controller *ctrl) { - int dummy; - if (!ctrl) return; - dummy = device_for_each_child(&ctrl->dev, NULL, - spmi_ctrl_remove_device); + device_for_each_child(&ctrl->dev, NULL, spmi_ctrl_remove_device); device_del(&ctrl->dev); } EXPORT_SYMBOL_GPL(spmi_controller_remove); |