summaryrefslogtreecommitdiff
path: root/drivers/base/regmap/regmap-i2c.c
diff options
context:
space:
mode:
authorMark Brown <broonie@opensource.wolfsonmicro.com>2012-05-30 12:55:34 +0400
committerJean Delvare <khali@endymion.delvare>2012-05-30 12:55:34 +0400
commit14674e70119ea01549ce593d8901a797f8a90f74 (patch)
tree15474236bfa505aa396bf2892cbbee65e842b94b /drivers/base/regmap/regmap-i2c.c
parent838bfa6049fb84dc66c9c9bbeb3a968ec987fd3d (diff)
downloadlinux-14674e70119ea01549ce593d8901a797f8a90f74.tar.xz
i2c: Split I2C_M_NOSTART support out of I2C_FUNC_PROTOCOL_MANGLING
Since there are uses for I2C_M_NOSTART which are much more sensible and standard than most of the protocol mangling functionality (the main one being gather writes to devices where something like a register address needs to be inserted before a block of data) create a new I2C_FUNC_NOSTART for this feature and update all the users to use it. Also strengthen the disrecommendation of the protocol mangling while we're at it. In the case of regmap-i2c we remove the requirement for mangling as I2C_M_NOSTART is the only mangling feature which is being used. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Jean Delvare <khali@linux-fr.org>
Diffstat (limited to 'drivers/base/regmap/regmap-i2c.c')
-rw-r--r--drivers/base/regmap/regmap-i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/regmap/regmap-i2c.c b/drivers/base/regmap/regmap-i2c.c
index 5f6b2478bf17..fa6bf5279d28 100644
--- a/drivers/base/regmap/regmap-i2c.c
+++ b/drivers/base/regmap/regmap-i2c.c
@@ -42,7 +42,7 @@ static int regmap_i2c_gather_write(void *context,
/* If the I2C controller can't do a gather tell the core, it
* will substitute in a linear write for us.
*/
- if (!i2c_check_functionality(i2c->adapter, I2C_FUNC_PROTOCOL_MANGLING))
+ if (!i2c_check_functionality(i2c->adapter, I2C_FUNC_NOSTART))
return -ENOTSUPP;
xfer[0].addr = i2c->addr;