diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-17 23:45:02 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-17 23:45:02 +0100 |
commit | 6e9c6e87a662c6665053fc3cc7840ed6fa80414e (patch) | |
tree | 2c573ee6bd9e9d77b35ec956e3dfe8aca0ae6fa6 /drivers/base/component.c | |
parent | Staging: comedi: kcomedilib: replace deprecated simple_strtoul() with kstrtou... (diff) | |
parent | Linux 3.14-rc3 (diff) | |
download | linux-6e9c6e87a662c6665053fc3cc7840ed6fa80414e.tar.xz linux-6e9c6e87a662c6665053fc3cc7840ed6fa80414e.zip |
Merge 3.14-rc3 into staging-next
We want the fixes in this branch to make testing and future work easier.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/base/component.c')
-rw-r--r-- | drivers/base/component.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/base/component.c b/drivers/base/component.c index c53efe6c6d8e..c4778995cd72 100644 --- a/drivers/base/component.c +++ b/drivers/base/component.c @@ -133,9 +133,16 @@ static int try_to_bring_up_master(struct master *master, goto out; } + if (!devres_open_group(master->dev, NULL, GFP_KERNEL)) { + ret = -ENOMEM; + goto out; + } + /* Found all components */ ret = master->ops->bind(master->dev); if (ret < 0) { + devres_release_group(master->dev, NULL); + dev_info(master->dev, "master bind failed: %d\n", ret); master_remove_components(master); goto out; } @@ -166,6 +173,7 @@ static void take_down_master(struct master *master) { if (master->bound) { master->ops->unbind(master->dev); + devres_release_group(master->dev, NULL); master->bound = false; } |