Commit d4ab78d7 authored by Mark Brown's avatar Mark Brown

Merge remote-tracking branches 'regmap/topic/doc' and 'regmap/topic/flat' into regmap-next

...@@ -27,7 +27,7 @@ static int regcache_flat_init(struct regmap *map) ...@@ -27,7 +27,7 @@ static int regcache_flat_init(struct regmap *map)
int i; int i;
unsigned int *cache; unsigned int *cache;
if (!map || map->reg_stride_order < 0) if (!map || map->reg_stride_order < 0 || !map->max_register)
return -EINVAL; return -EINVAL;
map->cache = kcalloc(regcache_flat_get_index(map, map->max_register) map->cache = kcalloc(regcache_flat_get_index(map, map->max_register)
......
...@@ -529,7 +529,7 @@ EXPORT_SYMBOL_GPL(regcache_mark_dirty); ...@@ -529,7 +529,7 @@ EXPORT_SYMBOL_GPL(regcache_mark_dirty);
* regcache_cache_bypass: Put a register map into cache bypass mode * regcache_cache_bypass: Put a register map into cache bypass mode
* *
* @map: map to configure * @map: map to configure
* @cache_bypass: flag if changes should not be written to the hardware * @cache_bypass: flag if changes should not be written to the cache
* *
* When a register map is marked with the cache bypass option, writes * When a register map is marked with the cache bypass option, writes
* to the register map API will only update the hardware and not the * to the register map API will only update the hardware and not the
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment