public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Peter Zijlstra <peterz@infradead.org>
To: Fernand Sieber <sieberf@amazon.com>
Cc: kernel test robot <lkp@intel.com>,
	mingo@redhat.com, juri.lelli@redhat.com,
	vincent.guittot@linaro.org, dietmar.eggemann@arm.com,
	rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de,
	vschneid@redhat.com, oe-kbuild-all@lists.linux.dev,
	linux-kernel@vger.kernel.org, dwmw@amazon.co.uk,
	jschoenh@amazon.de, liuyuxua@amazon.com
Subject: Re: [PATCH] sched: Proxy yields to donor tasks
Date: Fri, 7 Nov 2025 09:25:33 +0100	[thread overview]
Message-ID: <20251107082533.GA1508773@noisy.programming.kicks-ass.net> (raw)
In-Reply-To: <20251107081254.110947-1-sieberf@amazon.com>

On Fri, Nov 07, 2025 at 10:12:53AM +0200, Fernand Sieber wrote:
> On Thu, Nov 07, 2025 at 02:31:16PM +0800, kernel test robot wrote:
> > sparse warnings: (new ones prefixed by >>)
> >
> >>> kernel/sched/rt.c:529:55: sparse: warning: incorrect type in initializer (different address spaces)
> >>> kernel/sched/rt.c:976:39: sparse: warning: incorrect type in initializer (different address spaces)
> 
> Thank you for the report.
> 
> The warnings occur because my patch changes scheduler yield functions from
> accessing rq->curr to rq->donor, both of which have identical __rcu annotations.
> These are pre-existing annotation issues in the scheduler code, which has been
> directly accessing RCU-annotated pointers without proper dereferencing, relying
> on runqueue lock protection instead.
> 
> If we do want to address these sparse warnings, I can make modifications like:
> 
> -               curr = rq->donor;
> +               curr = rcu_dereference_protected(rq->donor, lockdep_is_held(&rq->__lock));
> 
> This would have zero runtime overhead while satisfying sparse's RCU checking.
> 
> Peter, let me know if these warnings should be addressed.

Nah, I'm happy to ignore them to retain readable code :-)

  reply	other threads:[~2025-11-07  8:25 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-11-06 10:40 [PATCH] sched: Proxy yields to donor tasks Fernand Sieber
2025-11-06 10:57 ` Peter Zijlstra
2025-11-07  6:54 ` kernel test robot
2025-11-07  8:12   ` Fernand Sieber
2025-11-07  8:25     ` Peter Zijlstra [this message]
2025-11-11 11:37 ` [tip: sched/core] sched/proxy: Yield the donor task tip-bot2 for Fernand Sieber
  -- strict thread matches above, loose matches on Subject: below --
2025-10-21  5:14 [tip:sched/core] [sched/fair] 79104becf4: BUG:kernel_NULL_pointer_dereference,address kernel test robot
2025-10-21  6:39 ` Chen, Yu C
2025-10-21 11:04 ` Peter Zijlstra
2025-10-27 12:54   ` Peter Zijlstra
2025-10-27 13:14     ` Chen, Yu C
2025-10-27 13:55       ` Peter Zijlstra
2025-10-27 14:07         ` Peter Zijlstra
2025-10-27 14:09           ` Peter Zijlstra
2025-10-28  2:30             ` Chen, Yu C
2025-11-05 11:00               ` Peter Zijlstra
2025-11-05 12:06                 ` Philip Li
2025-11-07 10:16                   ` Philip Li
2025-11-07 10:53                     ` Peter Zijlstra
2025-11-04 21:04 ` Fernand Sieber
2025-11-05  8:43   ` Fernand Sieber
2025-11-05 11:03   ` Peter Zijlstra
2025-11-05 12:28   ` Peter Zijlstra
2025-11-06 10:54     ` Fernand Sieber
2025-11-06 23:57       ` John Stultz
2025-11-07  8:18         ` Fernand Sieber

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=20251107082533.GA1508773@noisy.programming.kicks-ass.net \
    --to=peterz@infradead.org \
    --cc=bsegall@google.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=dwmw@amazon.co.uk \
    --cc=jschoenh@amazon.de \
    --cc=juri.lelli@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=liuyuxua@amazon.com \
    --cc=lkp@intel.com \
    --cc=mgorman@suse.de \
    --cc=mingo@redhat.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=rostedt@goodmis.org \
    --cc=sieberf@amazon.com \
    --cc=vincent.guittot@linaro.org \
    --cc=vschneid@redhat.com \
    /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