From: Mark Brown Date: Mon, 6 Feb 2012 18:02:06 +0000 (+0000) Subject: regmap: Add debugfs information for the cache status X-Git-Tag: v3.4-rc1~126^2~17 X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=commitdiff_plain;h=028a01e601487b5991b70dba506dfe87d83543f6;p=linux.git regmap: Add debugfs information for the cache status Show all the cache status flags in debugfs if we have a cache. Signed-off-by: Mark Brown --- diff --git a/drivers/base/regmap/regmap-debugfs.c b/drivers/base/regmap/regmap-debugfs.c index 6f397476e27c..b3b4b8f7f409 100644 --- a/drivers/base/regmap/regmap-debugfs.c +++ b/drivers/base/regmap/regmap-debugfs.c @@ -192,6 +192,15 @@ void regmap_debugfs_init(struct regmap *map) debugfs_create_file("access", 0400, map->debugfs, map, ®map_access_fops); } + + if (map->cache_type) { + debugfs_create_bool("cache_only", 0400, map->debugfs, + &map->cache_only); + debugfs_create_bool("cache_dirty", 0400, map->debugfs, + &map->cache_dirty); + debugfs_create_bool("cache_bypass", 0400, map->debugfs, + &map->cache_bypass); + } } void regmap_debugfs_exit(struct regmap *map)