lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aNJKsO4vv_FnBSOe@gpd4>
Date: Tue, 23 Sep 2025 09:22:24 +0200
From: Andrea Righi <arighi@...dia.com>
To: Tejun Heo <tj@...nel.org>
Cc: David Vernet <void@...ifault.com>, Changwoo Min <changwoo@...lia.com>,
	linux-kernel@...r.kernel.org, sched-ext@...ts.linux.dev
Subject: Re: [PATCH 3/7] sched_ext: Fix stray scx_root usage in
 task_can_run_on_remote_rq()

On Sun, Sep 21, 2025 at 03:32:42PM -1000, Tejun Heo wrote:
> task_can_run_on_remote_rq() takes @sch but it is using scx_root when
> incrementing SCX_EV_DISPATCH_LOCAL_DSQ_OFFLINE, which is inconsistent and
> gets in the way of implementing multiple scheduler support. Use @sch
> instead. As currently scx_root is the only possible scheduler instance, this
> doesn't cause any behavior changes.
> 
> Signed-off-by: Tejun Heo <tj@...nel.org>

Good catch.

Acked-by: Andrea Righi <arighi@...dia.com>

> ---
>  kernel/sched/ext.c | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
> 
> diff --git a/kernel/sched/ext.c b/kernel/sched/ext.c
> index df433f6fab4b..5801ac676d59 100644
> --- a/kernel/sched/ext.c
> +++ b/kernel/sched/ext.c
> @@ -1622,8 +1622,7 @@ static bool task_can_run_on_remote_rq(struct scx_sched *sch,
>  
>  	if (!scx_rq_online(rq)) {
>  		if (enforce)
> -			__scx_add_event(scx_root,
> -					SCX_EV_DISPATCH_LOCAL_DSQ_OFFLINE, 1);
> +			__scx_add_event(sch, SCX_EV_DISPATCH_LOCAL_DSQ_OFFLINE, 1);
>  		return false;
>  	}
>  
> -- 
> 2.51.0
> 

-Andrea

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ