Skip to contentSkip to conversation

PM / Domains: Always enable debugfs support if available

PATCH In review Jon Hunter 3 participants 3 messages Aug 11, 2016 – Aug 19, 2016

Subsystems (4)
lore
Share & tools
lore

Jon Hunter

author
#0 lore raw

PATCH 1/1 PM / Domains: Always enable debugfs support if available

Debugfs support for PM domains is only enabled if both CONFIG_PM_DEBUG and CONFIG_PM_ADVANCED_DEBUG are enabled. CONFIG_PM_ADVANCED_DEBUG is described as "extra PM attributes in sysfs for low-level debugging/testing" which does not seem related.

Given that the debugfs for PM domains only allows users to view the state of the PM domains, always enable debugfs support for PM domains if PM domains and debugfs support is enabled.

---
 drivers/base/power/domain.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/base/power/domain.c +2 -2
index a1f2aff33997..058c8b6d2871 100644
@@ -1636,7 +1636,7 @@ EXPORT_SYMBOL_GPL(genpd_dev_pm_attach);
 
 /***        debugfs support        ***/
 
-#ifdef CONFIG_PM_ADVANCED_DEBUG
+#ifdef CONFIG_DEBUG_FS
 #include <linux/pm.h>
 #include <linux/device.h>
 #include <linux/debugfs.h>
@@ -1784,4 +1784,4 @@ static void __exit pm_genpd_debug_exit(void)
 	debugfs_remove_recursive(pm_genpd_debugfs_dir);
 }
 __exitcall(pm_genpd_debug_exit);
-#endif /* CONFIG_PM_ADVANCED_DEBUG */
+#endif /* CONFIG_DEBUG_FS */
Signature · 1 line
2.1.4
Acked-by on v1 1/1
#1 lore raw
Quoted 10 lines · Jon Hunter

Debugfs support for PM domains is only enabled if both CONFIG_PM_DEBUG and CONFIG_PM_ADVANCED_DEBUG are enabled. CONFIG_PM_ADVANCED_DEBUG is described as "extra PM attributes in sysfs for low-level debugging/testing" which does not seem related.

Given that the debugfs for PM domains only allows users to view the state of the PM domains, always enable debugfs support for PM domains if PM domains and debugfs support is enabled.

Gr{oetje,eeting}s,

Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]

In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds

Acked-by on v1 1/1
#2 lore raw
In reply to Jon Hunter
Quoted 10 lines · Jon Hunter

Debugfs support for PM domains is only enabled if both CONFIG_PM_DEBUG and CONFIG_PM_ADVANCED_DEBUG are enabled. CONFIG_PM_ADVANCED_DEBUG is described as "extra PM attributes in sysfs for low-level debugging/testing" which does not seem related.

Given that the debugfs for PM domains only allows users to view the state of the PM domains, always enable debugfs support for PM domains if PM domains and debugfs support is enabled.

Kind regards
Uffe

Quoted 26 lines
---
 drivers/base/power/domain.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/base/power/domain.c +2 -3
index a1f2aff33997..058c8b6d2871 100644
@@ -1636,7 +1636,7 @@ EXPORT_SYMBOL_GPL(genpd_dev_pm_attach);
 
 /***        debugfs support        ***/
 
-#ifdef CONFIG_PM_ADVANCED_DEBUG
+#ifdef CONFIG_DEBUG_FS
 #include <linux/pm.h>
 #include <linux/device.h>
 #include <linux/debugfs.h>
@@ -1784,4 +1784,4 @@ static void __exit pm_genpd_debug_exit(void)
        debugfs_remove_recursive(pm_genpd_debugfs_dir);
 }
 __exitcall(pm_genpd_debug_exit);
-#endif /* CONFIG_PM_ADVANCED_DEBUG */
+#endif /* CONFIG_DEBUG_FS */
--

2.1.4