All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Jim Cromie <jim.cromie@gmail.com>
Cc: oe-kbuild-all@lists.linux.dev
Subject: [jimc:dd-fix-5e 24/24] lib/dynamic_debug.c:935:5: warning: no previous prototype for '__dynamic_emit_prefix'
Date: Sun, 3 Sep 2023 20:26:35 +0800	[thread overview]
Message-ID: <202309032002.ZOwLocfG-lkp@intel.com> (raw)

tree:   https://github.com/jimc/linux.git dd-fix-5e
head:   69b58a07013be2ff9c21e29b48cce3de6d963f11
commit: 69b58a07013be2ff9c21e29b48cce3de6d963f11 [24/24] dyndbg: use assoc-array to cache prefixes
config: x86_64-rhel-8.3 (https://download.01.org/0day-ci/archive/20230903/202309032002.ZOwLocfG-lkp@intel.com/config)
compiler: gcc-12 (Debian 12.2.0-14) 12.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20230903/202309032002.ZOwLocfG-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202309032002.ZOwLocfG-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> lib/dynamic_debug.c:935:5: warning: no previous prototype for '__dynamic_emit_prefix' [-Wmissing-prototypes]
     935 | int __dynamic_emit_prefix(struct _ddebug *desc, char *buf, int pos)
         |     ^~~~~~~~~~~~~~~~~~~~~


vim +/__dynamic_emit_prefix +935 lib/dynamic_debug.c

   934	
 > 935	int __dynamic_emit_prefix(struct _ddebug *desc, char *buf, int pos)
   936	{
   937		int pos_after_tid;
   938		char *prefix;
   939	        struct assoc_array_edit *edit;
   940	
   941		prefix = assoc_array_find(&ddebug_prefix_cache, &ddprefix_aa_ops, desc);
   942		if (prefix) {
   943	                pos += snprintf(buf + pos, remaining(pos), "%s:", prefix);
   944			return pos;
   945		}
   946		pos_after_tid = pos;
   947	
   948	        if (desc->flags & _DPRINTK_FLAGS_INCL_MODNAME)
   949			pos += snprintf(buf + pos, remaining(pos), "%s:",
   950					desc->modname);
   951		if (desc->flags & _DPRINTK_FLAGS_INCL_FUNCNAME)
   952			pos += snprintf(buf + pos, remaining(pos), "%s:",
   953					desc->function);
   954	
   955		prefix = kstrdup(buf + pos_after_tid, GFP_KERNEL);
   956		edit = assoc_array_insert(&ddebug_prefix_cache, &ddprefix_aa_ops, desc, prefix);
   957	
   958		v4pr_info("caching prefix: %s for %px\n", prefix, desc);
   959		desc->flags |= _DPRINTK_FLAGS_PREFIX_CACHED;
   960		assoc_array_apply_edit(edit);
   961	
   962		return pos;
   963	}
   964	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

                 reply	other threads:[~2023-09-03 12:26 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202309032002.ZOwLocfG-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=jim.cromie@gmail.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.