change desc_*() macros to call __desc_*() functions, and #if 0 the comparisons to the site->_* ref. This makes the _ddebug.site pointer unneccesary. Signed-off-by: Jim Cromie <jim.cromie@xxxxxxxxx> --- lib/dynamic_debug.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/lib/dynamic_debug.c b/lib/dynamic_debug.c index 48564625a37e..fb72a7b05b01 100644 --- a/lib/dynamic_debug.c +++ b/lib/dynamic_debug.c @@ -223,9 +223,9 @@ static struct ddebug_class_map *ddebug_find_valid_class(struct ddebug_table cons return NULL; } -#define desc_modname(d) (d)->site->_modname -#define desc_filename(d) (d)->site->_filename -#define desc_function(d) (d)->site->_function +#define desc_modname(d) __desc_modname(d) +#define desc_filename(d) __desc_filename(d) +#define desc_function(d) __desc_function(d) /* * tmp accessors, they cheat and seek a match in builtins. Obviously * this wont work for loaded modules, but doesnt work at all yet. @@ -235,11 +235,11 @@ static const char * __desc_function(struct _ddebug const *dp) struct maple_tree *mt = &mt_funcs; void *ret = mtree_load(mt, (unsigned long)dp); - +#if 0 if (ret != desc_function(dp)) pr_err("mt-load func %lx got %s want %s\n", (unsigned long)dp, (char*)ret, desc_function(dp)); - +#endif return ret; } @@ -248,11 +248,11 @@ static const char * __desc_filename(struct _ddebug const *dp) struct maple_tree *mt = &mt_files; void *ret = mtree_load(mt, (unsigned long)dp); - +#if 0 if (ret != desc_filename(dp)) pr_err("mt-load file %lx got %s want %s\n", (unsigned long)dp, (char*)ret, desc_filename(dp)); - +#endif return ret; } @@ -261,11 +261,11 @@ static const char * __desc_modname(struct _ddebug const *dp) struct maple_tree *mt = &mt_mods; void *ret = mtree_load(mt, (unsigned long)dp); - +#if 0 if (ret != desc_modname(dp)) pr_err("mt-load mod %lx got %s want %s\n", (unsigned long)dp, (char*)ret, desc_modname(dp)); - +#endif return ret; } @@ -1441,7 +1441,7 @@ static void ddebug_condense_sites(struct _ddebug_info *di) i = 0; for (; i < di->num_descs; i++, cur_dd++, cur_ds++) { - BUG_ON(site_function(cur_ds) != desc_function(cur_dd)); + //BUG_ON(site_function(cur_ds) != desc_function(cur_dd)); if (!strcmp(site_function(cur_ds), site_function(func_ds))) continue; -- 2.41.0