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: <20151203100018.GO11639@twins.programming.kicks-ass.net>
Date:	Thu, 3 Dec 2015 11:00:18 +0100
From:	Peter Zijlstra <peterz@...radead.org>
To:	Tejun Heo <tj@...nel.org>
Cc:	Ulrich Obergfell <uobergfe@...hat.com>,
	Ingo Molnar <mingo@...hat.com>,
	Andrew Morton <akpm@...ux-foundation.org>,
	linux-kernel@...r.kernel.org, kernel-team@...com
Subject: Re: [PATCH 1/2] watchdog: introduce touch_softlockup_watchdog_sched()

On Thu, Dec 03, 2015 at 10:33:50AM +0100, Peter Zijlstra wrote:
> On Wed, Dec 02, 2015 at 07:28:10PM -0500, Tejun Heo wrote:
> > Hello,
> > 
> > There haven't been too many workqueue stall bugs; however, good part
> > of them have been pretty painful to track down because there's no
> > lockup detection mechanism for workqueue and it isn't easy to tell
> > what's going on with workqueues; furthermore, some requirements are
> > tricky to get right - e.g. it's not too difficult to miss
> > WQ_MEM_RECLAIM for a workqueue which runs a work item which is flushed
> > by something which sits in the reclaim path.
> 
> have you considered something as simple as:
> 
> 	WARN_ON(current->reclaim_state && !WQ_MEM_RECLAIM);
> 
> ?

Alternatively, you can 'abuse' the lockdep reclaim bits by marking
!MEM_RECLAIM workqueue 'locks' with lockdep_trace_alloc(GFP_KERNEL),
that way lockdep will yell if they get used in a reclaim context.

This might be a tad tricky in that you need 2 sets of (lockdep) keys for
things.
--
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