aboutsummaryrefslogtreecommitdiffstats
path: root/lib/dynamic_debug.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/dynamic_debug.c')
-rw-r--r--lib/dynamic_debug.c12
1 files changed, 11 insertions, 1 deletions
diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c
index 66e0ec4d21f7..76da6aa66ce7 100644
--- a/lib/dynamic_debug.c
+++ b/lib/dynamic_debug.c
@@ -970,7 +970,8 @@ static int __init dynamic_debug_init(void)
970 const char *modname = NULL; 970 const char *modname = NULL;
971 char *cmdline; 971 char *cmdline;
972 int ret = 0; 972 int ret = 0;
973 int n = 0; 973 int n = 0, entries = 0, modct = 0;
974 int verbose_bytes = 0;
974 975
975 if (__start___verbose == __stop___verbose) { 976 if (__start___verbose == __stop___verbose) {
976 pr_warn("_ddebug table is empty in a " 977 pr_warn("_ddebug table is empty in a "
@@ -981,7 +982,12 @@ static int __init dynamic_debug_init(void)
981 modname = iter->modname; 982 modname = iter->modname;
982 iter_start = iter; 983 iter_start = iter;
983 for (; iter < __stop___verbose; iter++) { 984 for (; iter < __stop___verbose; iter++) {
985 entries++;
986 verbose_bytes += strlen(iter->modname) + strlen(iter->function)
987 + strlen(iter->filename) + strlen(iter->format);
988
984 if (strcmp(modname, iter->modname)) { 989 if (strcmp(modname, iter->modname)) {
990 modct++;
985 ret = ddebug_add_module(iter_start, n, modname); 991 ret = ddebug_add_module(iter_start, n, modname);
986 if (ret) 992 if (ret)
987 goto out_err; 993 goto out_err;
@@ -996,6 +1002,10 @@ static int __init dynamic_debug_init(void)
996 goto out_err; 1002 goto out_err;
997 1003
998 ddebug_init_success = 1; 1004 ddebug_init_success = 1;
1005 vpr_info("%d modules, %d entries and %d bytes in ddebug tables,"
1006 " %d bytes in (readonly) verbose section\n",
1007 modct, entries, (int)( modct * sizeof(struct ddebug_table)),
1008 verbose_bytes + (int)(__stop___verbose - __start___verbose));
999 1009
1000 /* apply ddebug_query boot param, dont unload tables on err */ 1010 /* apply ddebug_query boot param, dont unload tables on err */
1001 if (ddebug_setup_string[0] != '\0') { 1011 if (ddebug_setup_string[0] != '\0') {