diff --git a/Kconfig b/Kconfig index b7d2e6f49c62f..e0cfa1c37bec6 100644 --- a/Kconfig +++ b/Kconfig @@ -2363,6 +2363,70 @@ config DEBUG_RESET_INFO endif # DEBUG_RESET +config DEBUG_PINCTRL + bool "PINCTRL Debug Features" + default n + depends on PINCTRL + ---help--- + Enable PINCTRL debug features. + +if DEBUG_PINCTRL + +config DEBUG_PINCTRL_ERROR + bool "PINCTRL Error Output" + default n + depends on DEBUG_ERROR + ---help--- + Enable PINCTRL driver error output to SYSLOG. + +config DEBUG_PINCTRL_WARN + bool "PINCTRL Warnings Output" + default n + depends on DEBUG_WARN + ---help--- + Enable PINCTRL driver warning output to SYSLOG. + +config DEBUG_PINCTRL_INFO + bool "PINCTRL Informational Output" + default n + depends on DEBUG_INFO + ---help--- + Enable PINCTRL driver informational output to SYSLOG. + +endif # DEBUG_PINCTRL + +config DEBUG_CLK + bool "CLK Debug Features" + default n + depends on CLK + ---help--- + Enable CLK debug features. + +if DEBUG_CLK + +config DEBUG_CLK_ERROR + bool "CLK Error Output" + default n + depends on DEBUG_ERROR + ---help--- + Enable CLK driver error output to SYSLOG. + +config DEBUG_CLK_WARN + bool "CLK Warnings Output" + default n + depends on DEBUG_WARN + ---help--- + Enable CLK driver warning output to SYSLOG. + +config DEBUG_CLK_INFO + bool "CLK Informational Output" + default n + depends on DEBUG_INFO + ---help--- + Enable CLK driver informational output to SYSLOG. + +endif # DEBUG_CLK + config DEBUG_IPC bool "IPC (Inter-Process Communication) Debug Features" default n diff --git a/include/nuttx/debug.h b/include/nuttx/debug.h index 14d3678201cb7..3cb236db3f929 100644 --- a/include/nuttx/debug.h +++ b/include/nuttx/debug.h @@ -959,6 +959,42 @@ # define rstinfo _none #endif +#ifdef CONFIG_DEBUG_PINCTRL_ERROR +# define pinctrlerr _err +#else +# define pinctrlerr _none +#endif + +#ifdef CONFIG_DEBUG_PINCTRL_WARN +# define pinctrlwarn _warn +#else +# define pinctrlwarn _none +#endif + +#ifdef CONFIG_DEBUG_PINCTRL_INFO +# define pinctrlinfo _info +#else +# define pinctrlinfo _none +#endif + +#ifdef CONFIG_DEBUG_CLK_ERROR +# define clkerr _err +#else +# define clkerr _none +#endif + +#ifdef CONFIG_DEBUG_CLK_WARN +# define clkwarn _warn +#else +# define clkwarn _none +#endif + +#ifdef CONFIG_DEBUG_CLK_INFO +# define clkinfo _info +#else +# define clkinfo _none +#endif + #ifdef CONFIG_DEBUG_IPC_ERROR # define ipcerr _err #else