From: Leon Romanovsky <leon@leon.nu>
To: sbkim73@samsung.com, sameo@linux.intel.com
Cc: linux-kernel@vger.kernel.org, Leon Romanovsky <leon@leon.nu>
Subject: [PATCH] drivers: mfd: sec-core: Remove explicit call to mfd_remove_devices
Date: Wed, 15 May 2013 18:00:48 +0300 [thread overview]
Message-ID: <1368630048-27007-1-git-send-email-leon@leon.nu> (raw)
In case mfd_add_devices will fail, it will call to mfd_remove_devices
by itself and return non-zero value.
Signed-off-by: Leon Romanovsky <leon@leon.nu>
---
drivers/mfd/sec-core.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/mfd/sec-core.c b/drivers/mfd/sec-core.c
index 5b740a3..c93ed3d 100644
--- a/drivers/mfd/sec-core.c
+++ b/drivers/mfd/sec-core.c
@@ -230,13 +230,12 @@ static int sec_pmic_probe(struct i2c_client *i2c,
BUG();
}
- if (ret < 0)
+ if (ret)
goto err;
return ret;
err:
- mfd_remove_devices(sec_pmic->dev);
sec_irq_exit(sec_pmic);
i2c_unregister_device(sec_pmic->rtc);
return ret;
--
1.8.1.5
next reply other threads:[~2013-05-15 15:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-05-15 15:00 Leon Romanovsky [this message]
2013-05-16 22:13 ` [PATCH] drivers: mfd: sec-core: Remove explicit call to mfd_remove_devices Samuel Ortiz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1368630048-27007-1-git-send-email-leon@leon.nu \
--to=leon@leon.nu \
--cc=linux-kernel@vger.kernel.org \
--cc=sameo@linux.intel.com \
--cc=sbkim73@samsung.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox