Lines Matching refs:map

3  * Register map access API internal header
36 void (*format_write)(struct regmap *map,
46 struct regmap *map;
157 /* if set, the HW registers are known to match map->reg_defaults */
186 int (*init)(struct regmap *map);
187 int (*exit)(struct regmap *map);
189 void (*debugfs_init)(struct regmap *map);
191 int (*read)(struct regmap *map, unsigned int reg, unsigned int *value);
192 int (*write)(struct regmap *map, unsigned int reg, unsigned int value);
193 int (*sync)(struct regmap *map, unsigned int min, unsigned int max);
194 int (*drop)(struct regmap *map, unsigned int min, unsigned int max);
197 bool regmap_cached(struct regmap *map, unsigned int reg);
198 bool regmap_writeable(struct regmap *map, unsigned int reg);
199 bool regmap_readable(struct regmap *map, unsigned int reg);
200 bool regmap_volatile(struct regmap *map, unsigned int reg);
201 bool regmap_precious(struct regmap *map, unsigned int reg);
202 bool regmap_writeable_noinc(struct regmap *map, unsigned int reg);
203 bool regmap_readable_noinc(struct regmap *map, unsigned int reg);
205 int _regmap_write(struct regmap *map, unsigned int reg,
211 struct regmap *map;
237 extern void regmap_debugfs_init(struct regmap *map);
238 extern void regmap_debugfs_exit(struct regmap *map);
240 static inline void regmap_debugfs_disable(struct regmap *map)
242 map->debugfs_disable = true;
247 static inline void regmap_debugfs_init(struct regmap *map) { }
248 static inline void regmap_debugfs_exit(struct regmap *map) { }
249 static inline void regmap_debugfs_disable(struct regmap *map) { }
253 int regcache_init(struct regmap *map, const struct regmap_config *config);
254 void regcache_exit(struct regmap *map);
255 int regcache_read(struct regmap *map,
257 int regcache_write(struct regmap *map,
259 int regcache_sync(struct regmap *map);
260 int regcache_sync_block(struct regmap *map, void *block,
264 bool regcache_reg_needs_sync(struct regmap *map, unsigned int reg,
267 static inline const void *regcache_get_val_addr(struct regmap *map,
271 return base + (map->cache_word_size * idx);
274 unsigned int regcache_get_val(struct regmap *map, const void *base,
276 void regcache_set_val(struct regmap *map, void *base, unsigned int idx,
278 int regcache_lookup_reg(struct regmap *map, unsigned int reg);
279 int regcache_sync_val(struct regmap *map, unsigned int reg, unsigned int val);
281 int _regmap_raw_write(struct regmap *map, unsigned int reg,
294 static inline const char *regmap_name(const struct regmap *map)
296 if (map->dev)
297 return dev_name(map->dev);
299 return map->name;
302 static inline unsigned int regmap_get_offset(const struct regmap *map,
305 if (map->reg_stride_order >= 0)
306 return index << map->reg_stride_order;
308 return index * map->reg_stride;
311 static inline unsigned int regcache_get_index_by_order(const struct regmap *map,
314 return reg >> map->reg_stride_order;
326 * Create a test register map with data stored in RAM, not intended