From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1750953AbcCKRwX (ORCPT ); Fri, 11 Mar 2016 12:52:23 -0500 Received: from mail-yw0-f172.google.com ([209.85.161.172]:33752 "EHLO mail-yw0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750892AbcCKRwT (ORCPT ); Fri, 11 Mar 2016 12:52:19 -0500 Date: Fri, 11 Mar 2016 12:52:16 -0500 From: Tejun Heo To: Adrian Hunter Cc: Peter Zijlstra , Ulrich Obergfell , Ingo Molnar , Andrew Morton , linux-kernel@vger.kernel.org, kernel-team@fb.com Subject: Re: [PATCH] workqueue: warn if memory reclaim tries to flush !WQ_MEM_RECLAIM workqueue Message-ID: <20160311175216.GK24046@htj.duckdns.org> References: <20151203002810.GJ19878@mtj.duckdns.org> <20151203093350.GP17308@twins.programming.kicks-ass.net> <20151203100018.GO11639@twins.programming.kicks-ass.net> <20151203144811.GA27463@mtj.duckdns.org> <20151203150442.GR17308@twins.programming.kicks-ass.net> <20151203150604.GC27463@mtj.duckdns.org> <20151203192616.GJ27463@mtj.duckdns.org> <56E18EF6.1010006@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <56E18EF6.1010006@intel.com> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, On Thu, Mar 10, 2016 at 05:12:54PM +0200, Adrian Hunter wrote: > > @@ -2711,6 +2744,8 @@ static bool start_flush_work(struct work > > pwq = worker->current_pwq; > > } > > > > + check_flush_dependency(pwq->wq, work); > > + > > insert_wq_barrier(pwq, barr, work, worker); > > spin_unlock_irq(&pool->lock); > > I am hitting the warnings when using cancel_delayed_work_sync(). I would > have thought that forward progress would still be guaranteed in that case. > Is it true that it is not? I'm not sure I understand what you're trying to say. If you're trying to do cancel_delayed_work_sync() from a memreclaim wq on a work item which is executing on !memreclaim wq, that'd be an incorrect thing to do as that can deadlock the memreclaim wq under memory pressure. Thanks. -- tejun