]> git.baikalelectronics.ru Git - kernel.git/commit
regmap: fix page selection for noinc reads
authorDmitry Baryshkov <dmitry.baryshkov@linaro.org>
Thu, 17 Sep 2020 15:34:04 +0000 (18:34 +0300)
committerMark Brown <broonie@kernel.org>
Mon, 21 Sep 2020 19:58:01 +0000 (20:58 +0100)
commit4560b025e733fbef44b6c2f458784b45e2c4afdb
treebdd828476621322c7587a64f9fafdd7ec1b69ef5
parente5c298cc0834f37712345ba1a5affc3b19df588b
regmap: fix page selection for noinc reads

Non-incrementing reads can fail if register + length crosses page
border. However for non-incrementing reads we should not check for page
border crossing. Fix this by passing additional flag to _regmap_raw_read
and passing length to _regmap_select_page basing on the flag.

Signed-off-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Fixes: 55e2ef973f3d ("regmap: Add regmap_noinc_read API")
Link: https://lore.kernel.org/r/20200917153405.3139200-1-dmitry.baryshkov@linaro.org
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap.c