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: <20241014082745.GT17263@noisy.programming.kicks-ass.net>
Date: Mon, 14 Oct 2024 10:27:45 +0200
From: Peter Zijlstra <peterz@...radead.org>
To: Anjali Kulkarni <anjali.k.kulkarni@...cle.com>
Cc: davem@...emloft.net, Liam.Howlett@...cle.com, edumazet@...gle.com,
	kuba@...nel.org, pabeni@...hat.com, mingo@...hat.com,
	juri.lelli@...hat.com, vincent.guittot@...aro.org,
	dietmar.eggemann@....com, rostedt@...dmis.org, bsegall@...gle.com,
	mgorman@...e.de, vschneid@...hat.com, jiri@...nulli.us,
	linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
	akpm@...ux-foundation.org, shuah@...nel.org,
	linux-kselftest@...r.kernel.org, peili.io@...cle.com
Subject: Re: [PATCH net-next v1 1/3] connector/cn_proc: Add hash table for
 threads

On Sun, Oct 13, 2024 at 10:06:15AM -0700, Anjali Kulkarni wrote:

> +	if (unlikely(task->flags & PF_EXIT_NOTIFY)) {
> +		task_lock(task);
> +		task->flags &= ~PF_EXIT_NOTIFY;
> +		task_unlock(task);
> +

> @@ -413,6 +440,15 @@ static void cn_proc_mcast_ctl(struct cn_msg *msg,
>  	if (msg->len == sizeof(*pinput)) {
>  		pinput = (struct proc_input *)msg->data;
>  		mc_op = pinput->mcast_op;
> +		if (mc_op == PROC_CN_MCAST_NOTIFY) {
> +			pr_debug("%s: Received PROC_CN_MCAST_NOTIFY, pid %d\n",
> +					__func__, current->pid);
> +			task_lock(current);
> +			current->flags |= PF_EXIT_NOTIFY;
> +			task_unlock(current);
> +			err = cn_add_elem(pinput->uexit_code, current->pid);
> +			return;
> +		}

You seem to think that task_lock protects task->flags ? Why?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ