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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Fri, 15 Jun 2012 10:44:37 +0900
From:	Tejun Heo <tj@...nel.org>
To:	Silas Boyd-Wickizer <sbw@....edu>
Cc:	Thomas Gleixner <tglx@...utronix.de>,
	LKML <linux-kernel@...r.kernel.org>,
	Peter Zijlstra <peterz@...radead.org>,
	Ingo Molnar <mingo@...nel.org>,
	"Srivatsa S. Bhat" <srivatsa.bhat@...ux.vnet.ibm.com>,
	Rusty Russell <rusty@...tcorp.com.au>,
	"Paul E. McKenney" <paulmck@...ux.vnet.ibm.com>
Subject: Re: [RFC patch 1/5] kthread: Implement park/unpark facility

On Thu, Jun 14, 2012 at 03:13:31PM -0700, Silas Boyd-Wickizer wrote:
> Hello,
> 
> Attached is a rough patch that uses park/unpark for workqueue idle
> threads.  The patch is a hack, it probably has bugs, and it certainly
> doesn't simplify the workqueue code.  Perhaps, however, the patch
> might be useful in guiding future changes to smp_boot_threads or
> workqueues.
> 
> A difficulty in applying park/unpark (or smp_boot_threads
> potentially), it that there is no single per-CPU thread for each CPU.
> That is, the thread that starts out as the initial worker/idle thread
> could be different from any thread that is idling when a CPU goes
> offline.  An additional complication is that a per-cpu worker that is
> idle may have initially been unbound (e.g. worker creation in the
> trustee_thread can cause this).

I haven't looked at it in any detail yet but if the goal is just
keeping workers around for temporarily down CPUs, workqueue changes
can be pretty simple.  I *think* all that's necessary is trustee not
butchering on cpu down.  wq already has mechanisms to recycle dangling
workers when a cpu comes back online.  I'll give it a shot next week.

Thanks.

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ