From: Peter Zijlstra <peterz@infradead.org>
To: kbuild-all@lists.01.org
Subject: Re: kernel/sched/core.c:5370:37: warning: cast between incompatible function types from 'long int (*)(void)' to 'int (*)(void)'
Date: Wed, 31 Mar 2021 09:32:21 +0200 [thread overview]
Message-ID: <YGQlhQ9rfkKBwUKB@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <202103311434.dpBaRaX7-lkp@intel.com>
[-- Attachment #1: Type: text/plain, Size: 1859 bytes --]
On Wed, Mar 31, 2021 at 02:15:41PM +0800, kernel test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: 5e46d1b78a03d52306f21f77a4e4a144b6d31486
> commit: 826bfeb37bb4302ee6042f330c4c0c757152bdb8 preempt/dynamic: Support dynamic preempt with preempt= boot option
> date: 6 weeks ago
> config: x86_64-randconfig-r011-20210331 (attached as .config)
> compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
> reproduce (this is a W=1 build):
> # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=826bfeb37bb4302ee6042f330c4c0c757152bdb8
> git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
> git fetch --no-tags linus master
> git checkout 826bfeb37bb4302ee6042f330c4c0c757152bdb8
> # save the attached .config to linux build tree
> make W=1 ARCH=x86_64
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> kernel/sched/core.c: In function 'schedule_tail':
> kernel/sched/core.c:4252:13: warning: variable 'rq' set but not used [-Wunused-but-set-variable]
> 4252 | struct rq *rq;
> | ^~
> In file included from include/linux/err.h:5,
> from include/linux/kthread.h:5,
> from include/trace/events/sched.h:8,
> from kernel/sched/core.c:10:
> kernel/sched/core.c: In function 'setup_preempt_mode':
> >> kernel/sched/core.c:5370:37: warning: cast between incompatible function types from 'long int (*)(void)' to 'int (*)(void)' [-Wcast-function-type]
That warning is broken IMO.
Still, I have a patch for this somewhere.. I'll try and push it out
sometime soon.
WARNING: multiple messages have this Message-ID (diff)
From: Peter Zijlstra <peterz@infradead.org>
To: kernel test robot <lkp@intel.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
Ingo Molnar <mingo@kernel.org>,
Frederic Weisbecker <frederic@kernel.org>
Subject: Re: kernel/sched/core.c:5370:37: warning: cast between incompatible function types from 'long int (*)(void)' to 'int (*)(void)'
Date: Wed, 31 Mar 2021 09:32:21 +0200 [thread overview]
Message-ID: <YGQlhQ9rfkKBwUKB@hirez.programming.kicks-ass.net> (raw)
In-Reply-To: <202103311434.dpBaRaX7-lkp@intel.com>
On Wed, Mar 31, 2021 at 02:15:41PM +0800, kernel test robot wrote:
> tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
> head: 5e46d1b78a03d52306f21f77a4e4a144b6d31486
> commit: 826bfeb37bb4302ee6042f330c4c0c757152bdb8 preempt/dynamic: Support dynamic preempt with preempt= boot option
> date: 6 weeks ago
> config: x86_64-randconfig-r011-20210331 (attached as .config)
> compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
> reproduce (this is a W=1 build):
> # https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=826bfeb37bb4302ee6042f330c4c0c757152bdb8
> git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
> git fetch --no-tags linus master
> git checkout 826bfeb37bb4302ee6042f330c4c0c757152bdb8
> # save the attached .config to linux build tree
> make W=1 ARCH=x86_64
>
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@intel.com>
>
> All warnings (new ones prefixed by >>):
>
> kernel/sched/core.c: In function 'schedule_tail':
> kernel/sched/core.c:4252:13: warning: variable 'rq' set but not used [-Wunused-but-set-variable]
> 4252 | struct rq *rq;
> | ^~
> In file included from include/linux/err.h:5,
> from include/linux/kthread.h:5,
> from include/trace/events/sched.h:8,
> from kernel/sched/core.c:10:
> kernel/sched/core.c: In function 'setup_preempt_mode':
> >> kernel/sched/core.c:5370:37: warning: cast between incompatible function types from 'long int (*)(void)' to 'int (*)(void)' [-Wcast-function-type]
That warning is broken IMO.
Still, I have a patch for this somewhere.. I'll try and push it out
sometime soon.
next prev parent reply other threads:[~2021-03-31 7:32 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-31 6:15 kernel/sched/core.c:5370:37: warning: cast between incompatible function types from 'long int (*)(void)' to 'int (*)(void)' kernel test robot
2021-03-31 6:15 ` kernel test robot
2021-03-31 7:32 ` Peter Zijlstra [this message]
2021-03-31 7:32 ` Peter Zijlstra
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=YGQlhQ9rfkKBwUKB@hirez.programming.kicks-ass.net \
--to=peterz@infradead.org \
--cc=kbuild-all@lists.01.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 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.