summaryrefslogtreecommitdiff
path: root/drivers/power/da9150-fg.c
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2018-02-08 10:23:44 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-04-24 09:32:06 +0200
commitd8ad6cb0222cb8ef107af59e574614d5bd447a55 (patch)
treee93be6e2c7df6569ecab3376e9a9dc3e5ec045d8 /drivers/power/da9150-fg.c
parent4c65e94eb476b8e7d806d7e36ca1f5f789e9804a (diff)
regmap: Fix reversed bounds check in regmap_raw_write()
commit f00e71091ab92eba52122332586c6ecaa9cd1a56 upstream. We're supposed to be checking that "val_len" is not too large but instead we check if it is smaller than the max. The only function affected would be regmap_i2c_smbus_i2c_write() in drivers/base/regmap/regmap-i2c.c. Strangely that function has its own limit check which returns an error if (count >= I2C_SMBUS_BLOCK_MAX) so it doesn't look like it has ever been able to do anything except return an error. Fixes: c335931ed9d2 ("regmap: Add raw_write/read checks for max_raw_write/read sizes") Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Mark Brown <broonie@kernel.org> Cc: stable@vger.kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/power/da9150-fg.c')
0 files changed, 0 insertions, 0 deletions