]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/commitdiff
regmap: debugfs: Improve warning message on debugfs_create_dir() failure
authorFabio Estevam <fabio.estevam@nxp.com>
Tue, 6 Mar 2018 02:13:04 +0000 (23:13 -0300)
committerMark Brown <broonie@kernel.org>
Tue, 6 Mar 2018 14:49:28 +0000 (14:49 +0000)
Currently when debugfs_create_dir() fails we receive a warning message
that provides no indication as to what was the directory entry that
failed to be created.

Improve the warning message by printing the directory name that failed
in order to help debugging.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/base/regmap/regmap-debugfs.c

index c84f5ceb015a8ed7f632473d4dd84839fee76782..87b562e49a435ffedac0f71b4652b669611e9a0e 100644 (file)
@@ -583,7 +583,8 @@ void regmap_debugfs_init(struct regmap *map, const char *name)
 
        map->debugfs = debugfs_create_dir(name, regmap_debugfs_root);
        if (!map->debugfs) {
-               dev_warn(map->dev, "Failed to create debugfs directory\n");
+               dev_warn(map->dev,
+                        "Failed to create %s debugfs directory\n", name);
 
                kfree(map->debugfs_name);
                map->debugfs_name = NULL;