regmap: Don't warn about cache only mode for devices with no cache
Subsystems (2)
Mark Brown
maintainerPATCH 1/1 regmap: Don't warn about cache only mode for devices with no cache
For devices with no cache it can make sense to use cache only mode as a mechanism for trapping writes to hardware which is inaccessible but since no cache is equivalent to cache bypass we force such devices into bypass mode. This means that our check that bypass and cache only mode aren't both enabled simultanously is less sensible for devices without a cache so relax it.
--- drivers/base/regmap/regcache.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/base/regmap/regcache.c +2 -1
@@ -495,7 +495,8 @@ EXPORT_SYMBOL_GPL(regcache_drop_region);void regcache_cache_only (struct regmap *map,bool enable) { map->lock (map->lock_arg); -WARN_ON (map->cache_bypass && enable); +WARN_ON (map->cache_type !=REGCACHE_NONE && + map->cache_bypass && enable); map->cache_only = enable;trace_regmap_cache_only (map, enable); map->unlock (map->lock_arg);
Signature · 1 line
2.30.2
Mark Brown
maintainerQuoted 8 lines · Mark Brown
For devices with no cache it can make sense to use cache only mode as a mechanism for trapping writes to hardware which is inaccessible but since no cache is equivalent to cache bypass we force such devices into bypass mode. This means that our check that bypass and cache only mode aren't both enabled simultanously is less sensible for devices without a cache so relax it.
[...]
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regmap.git for-next
Thanks!
[1/1] regmap: Don't warn about cache only mode for devices with no cache
commit: 3d0afe9cf1ef871a71596f990d7d2e60cc0b8669
All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.
You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.
If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.
Please add any relevant lists and maintainers to the CCs when replying to this mail.
Thanks,
Mark