Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Peter Zijlstra <peterz@infradead.org>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev,
	Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Subject: [peterz-queue:locking/futex 3/23] kernel/futex/waitwake.c:343: warning: expecting prototype for futex_wait_queue(). Prototype was for futex_do_wait() instead
Date: Wed, 7 May 2025 17:42:57 +0800	[thread overview]
Message-ID: <202505071708.iowmDlNC-lkp@intel.com> (raw)

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git locking/futex
head:   9140f57c1c1391a0343a08daea9cd53f56e51154
commit: 93f1b6d79a73b520b6875cf3babf4a09acc4eef0 [3/23] futex: Move futex_queue() into futex_wait_setup()
config: x86_64-kexec (https://download.01.org/0day-ci/archive/20250507/202505071708.iowmDlNC-lkp@intel.com/config)
compiler: clang version 20.1.2 (https://github.com/llvm/llvm-project 58df0ef89dd64126512e4ee27b4ac3fd8ddf6247)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250507/202505071708.iowmDlNC-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/202505071708.iowmDlNC-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> kernel/futex/waitwake.c:343: warning: expecting prototype for futex_wait_queue(). Prototype was for futex_do_wait() instead
>> kernel/futex/waitwake.c:585: warning: Function parameter or struct member 'task' not described in 'futex_wait_setup'


vim +343 kernel/futex/waitwake.c

a046f1a0d3e320 Peter Zijlstra 2021-09-23  335  
a046f1a0d3e320 Peter Zijlstra 2021-09-23  336  /**
a046f1a0d3e320 Peter Zijlstra 2021-09-23  337   * futex_wait_queue() - futex_queue() and wait for wakeup, timeout, or signal
a046f1a0d3e320 Peter Zijlstra 2021-09-23  338   * @hb:		the futex hash bucket, must be locked by the caller
a046f1a0d3e320 Peter Zijlstra 2021-09-23  339   * @q:		the futex_q to queue up on
a046f1a0d3e320 Peter Zijlstra 2021-09-23  340   * @timeout:	the prepared hrtimer_sleeper, or null for no timeout
a046f1a0d3e320 Peter Zijlstra 2021-09-23  341   */
93f1b6d79a73b5 Peter Zijlstra 2025-04-16  342  void futex_do_wait(struct futex_q *q, struct hrtimer_sleeper *timeout)
a046f1a0d3e320 Peter Zijlstra 2021-09-23 @343  {
a046f1a0d3e320 Peter Zijlstra 2021-09-23  344  	/* Arm the timer */
a046f1a0d3e320 Peter Zijlstra 2021-09-23  345  	if (timeout)
a046f1a0d3e320 Peter Zijlstra 2021-09-23  346  		hrtimer_sleeper_start_expires(timeout, HRTIMER_MODE_ABS);
a046f1a0d3e320 Peter Zijlstra 2021-09-23  347  
a046f1a0d3e320 Peter Zijlstra 2021-09-23  348  	/*
a046f1a0d3e320 Peter Zijlstra 2021-09-23  349  	 * If we have been removed from the hash list, then another task
a046f1a0d3e320 Peter Zijlstra 2021-09-23  350  	 * has tried to wake us, and we can skip the call to schedule().
a046f1a0d3e320 Peter Zijlstra 2021-09-23  351  	 */
a046f1a0d3e320 Peter Zijlstra 2021-09-23  352  	if (likely(!plist_node_empty(&q->list))) {
a046f1a0d3e320 Peter Zijlstra 2021-09-23  353  		/*
a046f1a0d3e320 Peter Zijlstra 2021-09-23  354  		 * If the timer has already expired, current will already be
a046f1a0d3e320 Peter Zijlstra 2021-09-23  355  		 * flagged for rescheduling. Only call schedule if there
a046f1a0d3e320 Peter Zijlstra 2021-09-23  356  		 * is no timeout, or if it has yet to expire.
a046f1a0d3e320 Peter Zijlstra 2021-09-23  357  		 */
a046f1a0d3e320 Peter Zijlstra 2021-09-23  358  		if (!timeout || timeout->task)
f5d39b02080914 Peter Zijlstra 2022-08-22  359  			schedule();
a046f1a0d3e320 Peter Zijlstra 2021-09-23  360  	}
a046f1a0d3e320 Peter Zijlstra 2021-09-23  361  	__set_current_state(TASK_RUNNING);
a046f1a0d3e320 Peter Zijlstra 2021-09-23  362  }
a046f1a0d3e320 Peter Zijlstra 2021-09-23  363  

:::::: The code at line 343 was first introduced by commit
:::::: a046f1a0d3e320cfee6bdac336416a537f49e7c6 futex: Split out wait/wake

:::::: TO: Peter Zijlstra <peterz@infradead.org>
:::::: CC: Peter Zijlstra <peterz@infradead.org>

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

                 reply	other threads:[~2025-05-07  9:43 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=202505071708.iowmDlNC-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=bigeasy@linutronix.de \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=peterz@infradead.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox