From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-170.mta0.migadu.com (out-170.mta0.migadu.com [91.218.175.170]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 78837187346 for ; Wed, 8 Jul 2026 04:54:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.170 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783486455; cv=none; b=s5ZB8IX7vcabu6pMh99pg682LhezhFkhA08qEP00ERibsmQkbtkqrVyARNWJiRTvEhJ0L+5ddX6DyaaR2VxQmMTLB5EUaY2zpYRQQ2/1wa9JT8onSAbPL8Yl9c56aF9nV6ANICjF7tlDdRRPbZ7g/v1A9LMlr+Z84I4qRtOpapQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1783486455; c=relaxed/simple; bh=k1xzwpyYF5r4F9cZZsbwh5TDo5nYRz00nlc6Cr/8giY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=D1xJ3bJj0GT6BrRQ2RdvUHAFXapgJPShsOxUv+h/hDNBo0reu+HGeUb9qID/fTRn5iQshzIgR4q+aGzlxrMufyy8KKXuTkYBbknnatYTZO5x/StMbmMMzl8TIi5vd57/zsbAqTl0OYwEjyaTj4AZcXchpzBn60xjztquKdyBcZM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=wpIfPKz+; arc=none smtp.client-ip=91.218.175.170 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="wpIfPKz+" Date: Tue, 7 Jul 2026 21:54:02 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1783486449; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=YYJF3gA/1Ye/A90bToo6yX1kaFD6rK2JjvsYHqITlZA=; b=wpIfPKz+65mMx+GejlSLjy7zupKfEQey6TPLi8ZdE+n68enKygIVFU7XjVkvpZLcaz3TuQ eyNaq3YCbZXEJlJOAjeL9G3BxUD/TxVJc0BykRldgXTFWVd4YAlILTGTgf7c5aDSjA2mVL 2qzZKh0nBfLXi6bL0ShDCdNIv56++0o= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Shakeel Butt To: Richard Chang Cc: Andrew Morton , Kairui Song , Qi Zheng , Barry Song , Axel Rasmussen , Yuanchu Xie , Wei Xu , Johannes Weiner , David Hildenbrand , Michal Hocko , Lorenzo Stoakes , Suren Baghdasaryan , "T . J . Mercier" , Martin Liu , Minchan Kim , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm: vmscan: abort proactive reclaim early when freezing Message-ID: References: <20260706081218.3438762-1-richardycc@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Migadu-Flow: FLOW_OUT On Wed, Jul 08, 2026 at 12:14:50PM +0800, Richard Chang wrote: > On Wed, Jul 8, 2026 at 3:48 AM Shakeel Butt wrote: > > > > Can you please explain how freezing operation was delayed due to proactive > > reclaim? > > > Hi Shakeel, > > When system suspend is initiated, the Power Management (PM) freezer > attempts to freeze all user-space processes by calling > freeze_processes(), signaling user space processes to enter the > refrigerator. When a user-space task writes to memory.reclaim to > trigger proactive reclaim, it executes in kernel context and enters > the reclaim loop. Currently the task does not check signal_pending() > within the inner loops, it cannot abort the reclaim pass early. It > continues reclaiming memory, ignoring the freeze request. The PM > freezer waits for all tasks to freeze. If the proactive reclaim task > remains in the inner loops longer than the freeze timeout, the freezer > times out, and suspend fails. What's so special about proactive reclaim? Why the same situation can not happen for global or memcg reclaim?