commit | db04328c167ff8e7c57f4a3532214aeada3a82fd | [log] [tgz] |
---|---|---|
author | Mark Brown <broonie@opensource.wolfsonmicro.com> | Tue Dec 11 01:14:11 2012 +0900 |
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | Tue Dec 11 01:29:39 2012 +0900 |
tree | a1c57616c3007b6d4fbb29a28f144ec89302917e | |
parent | cbc1938badc31f43ab77e92a9b1a51c4fe8b4113 [diff] |
regmap: debugfs: Avoid overflows for very small reads If count is less than the size of a register then we may hit integer wraparound when trying to move backwards to check if we're still in the buffer. Instead move the position forwards to check if it's still in the buffer, we are unlikely to be able to allocate a buffer sufficiently big to overflow here. Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: stable@vger.kernel.org