From: Mark Brown <broonie@kernel.org>
To: Lee Jones <lee.jones@linaro.org>,
Samuel Ortiz <sameo@linux.intel.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Marc Reilly <marc@cpdesign.com.au>,
u.kleine-koenig@pengutronix.de
Cc: linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org,
linaro-kernel@lists.linaro.org, Mark Brown <broonie@linaro.org>
Subject: [PATCH 1/3] mfd: mc13xxx: Don't require lock for simple register I/O
Date: Wed, 18 Sep 2013 19:06:25 +0100 [thread overview]
Message-ID: <1379527587-14567-1-git-send-email-broonie@kernel.org> (raw)
From: Mark Brown <broonie@linaro.org>
Since the conversion to regmap there has been no need for device level
locking for I/O as regmap provides locking so remove the locks.
Signed-off-by: Mark Brown <broonie@linaro.org>
---
drivers/mfd/mc13xxx-core.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/mfd/mc13xxx-core.c b/drivers/mfd/mc13xxx-core.c
index 2a9b100..dbbf8ee 100644
--- a/drivers/mfd/mc13xxx-core.c
+++ b/drivers/mfd/mc13xxx-core.c
@@ -158,8 +158,6 @@ int mc13xxx_reg_read(struct mc13xxx *mc13xxx, unsigned int offset, u32 *val)
{
int ret;
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
-
if (offset > MC13XXX_NUMREGS)
return -EINVAL;
@@ -172,8 +170,6 @@ EXPORT_SYMBOL(mc13xxx_reg_read);
int mc13xxx_reg_write(struct mc13xxx *mc13xxx, unsigned int offset, u32 val)
{
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
-
dev_vdbg(mc13xxx->dev, "[0x%02x] <- 0x%06x\n", offset, val);
if (offset > MC13XXX_NUMREGS || val > 0xffffff)
@@ -186,7 +182,6 @@ EXPORT_SYMBOL(mc13xxx_reg_write);
int mc13xxx_reg_rmw(struct mc13xxx *mc13xxx, unsigned int offset,
u32 mask, u32 val)
{
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
BUG_ON(val & ~mask);
dev_vdbg(mc13xxx->dev, "[0x%02x] <- 0x%06x (mask: 0x%06x)\n",
offset, val, mask);
--
1.8.4.rc3
WARNING: multiple messages have this Message-ID (diff)
From: Mark Brown <broonie@kernel.org>
To: Lee Jones <lee.jones@linaro.org>,
Samuel Ortiz <sameo@linux.intel.com>,
Liam Girdwood <lgirdwood@gmail.com>,
Marc Reilly <marc@cpdesign.com.au>,
<u.kleine-koenig@pengutronix.de>
Cc: linux-kernel@vger.kernel.org, alsa-devel@alsa-project.org,
linaro-kernel@lists.linaro.org, Mark Brown <broonie@linaro.org>
Subject: [PATCH 1/3] mfd: mc13xxx: Don't require lock for simple register I/O
Date: Wed, 18 Sep 2013 19:06:25 +0100 [thread overview]
Message-ID: <1379527587-14567-1-git-send-email-broonie@kernel.org> (raw)
From: Mark Brown <broonie@linaro.org>
Since the conversion to regmap there has been no need for device level
locking for I/O as regmap provides locking so remove the locks.
Signed-off-by: Mark Brown <broonie@linaro.org>
---
drivers/mfd/mc13xxx-core.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/mfd/mc13xxx-core.c b/drivers/mfd/mc13xxx-core.c
index 2a9b100..dbbf8ee 100644
--- a/drivers/mfd/mc13xxx-core.c
+++ b/drivers/mfd/mc13xxx-core.c
@@ -158,8 +158,6 @@ int mc13xxx_reg_read(struct mc13xxx *mc13xxx, unsigned int offset, u32 *val)
{
int ret;
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
-
if (offset > MC13XXX_NUMREGS)
return -EINVAL;
@@ -172,8 +170,6 @@ EXPORT_SYMBOL(mc13xxx_reg_read);
int mc13xxx_reg_write(struct mc13xxx *mc13xxx, unsigned int offset, u32 val)
{
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
-
dev_vdbg(mc13xxx->dev, "[0x%02x] <- 0x%06x\n", offset, val);
if (offset > MC13XXX_NUMREGS || val > 0xffffff)
@@ -186,7 +182,6 @@ EXPORT_SYMBOL(mc13xxx_reg_write);
int mc13xxx_reg_rmw(struct mc13xxx *mc13xxx, unsigned int offset,
u32 mask, u32 val)
{
- BUG_ON(!mutex_is_locked(&mc13xxx->lock));
BUG_ON(val & ~mask);
dev_vdbg(mc13xxx->dev, "[0x%02x] <- 0x%06x (mask: 0x%06x)\n",
offset, val, mask);
--
1.8.4.rc3
next reply other threads:[~2013-09-18 18:06 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-09-18 18:06 Mark Brown [this message]
2013-09-18 18:06 ` [PATCH 1/3] mfd: mc13xxx: Don't require lock for simple register I/O Mark Brown
2013-09-18 18:06 ` [PATCH 2/3] mfd: mc13xxx: Move SPI erratum workaround into SPI I/O function Mark Brown
2013-09-18 18:06 ` Mark Brown
2013-09-19 9:13 ` Lee Jones
2013-09-19 9:56 ` Mark Brown
2013-09-19 9:56 ` Mark Brown
2013-09-19 10:04 ` Lee Jones
2013-09-19 11:41 ` Mark Brown
2013-09-19 11:49 ` Lee Jones
2013-09-19 12:09 ` Mark Brown
2013-09-19 12:09 ` Mark Brown
2013-09-18 18:06 ` [PATCH 3/3] ASoC: mc13783: Use regmap directly from ASoC Mark Brown
2013-09-18 18:06 ` Mark Brown
-- strict thread matches above, loose matches on Subject: below --
2013-09-23 18:14 [PATCH 1/3] mfd: mc13xxx: Don't require lock for simple register I/O Mark Brown
2013-09-23 18:14 ` Mark Brown
2013-09-25 11:19 ` Lee Jones
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=1379527587-14567-1-git-send-email-broonie@kernel.org \
--to=broonie@kernel.org \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@linaro.org \
--cc=lee.jones@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=linaro-kernel@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=marc@cpdesign.com.au \
--cc=sameo@linux.intel.com \
--cc=u.kleine-koenig@pengutronix.de \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.