From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-185.mta0.migadu.com (out-185.mta0.migadu.com [91.218.175.185]) (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 4BA5A34107B for ; Thu, 20 Nov 2025 13:41:28 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.185 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763646090; cv=none; b=osvo3AA+uALRvVa154UR9rgMHHGkHhWqz2/0QkgGpIij3TW07IEJw4o/GhSxDl0QkKP3P9o1XWaUvKGj15/xXtS2oo5xduG32sNmry6sXauskmm5RyxMeUSnU5hgl5pRwgrtj/XWdNVcxrloMwrqohHM5Cj2b3LLwFgGi1oQIHc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763646090; c=relaxed/simple; bh=rpGbnRiA/SFZ982PFn/ZGwKYtq6o194ofin/OxpEpY4=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=YRL8QsOb0hMK8ZgklxK9mYHzaTnPWkZc8QyNajEkcSc4b6EbRy8la4gZk3G6xNyopIRGztJezb0I9Rc7eg4kWGhHJSokBWLikRm9MkMDGJJKz4LkRCqC1Kslx8MVOzlWIDSwsUXJHKYONzmpZNKBQWGxP5C+Aw0DXQe6pbw4N+c= 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=MRYO20LC; arc=none smtp.client-ip=91.218.175.185 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="MRYO20LC" Message-ID: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1763646086; 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=iiUwXuDwPsPo8P/JiH7Rc6iuaehlzYW3mvFReb61JcA=; b=MRYO20LC5Fn8ysYUK9k9irRH7GumJAbF7J9zObagPMYZVTcIKzaUpwAffATPRR0rSEby4B ohC0GJrFXrjXJIGTa6kWudW9h2GgghJHUJxrANhQg/E1dpccoCFh0uDl0mIVpojt7IGyP/ 6ZoSQQZNHbd7kPNULpfCrJ+wb9McQQk= Date: Thu, 20 Nov 2025 21:41:15 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Subject: Re: [PATCH v1 19/26] mm: swap: prevent lruvec release in swap module To: Harry Yoo Cc: hannes@cmpxchg.org, hughd@google.com, mhocko@suse.com, roman.gushchin@linux.dev, shakeel.butt@linux.dev, muchun.song@linux.dev, david@redhat.com, lorenzo.stoakes@oracle.com, ziy@nvidia.com, imran.f.khan@oracle.com, kamalesh.babulal@oracle.com, axelrasmussen@google.com, yuanchu@google.com, weixugc@google.com, akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org, Muchun Song References: X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Qi Zheng In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_OUT On 11/20/25 5:52 PM, Harry Yoo wrote: > On Tue, Oct 28, 2025 at 09:58:32PM +0800, Qi Zheng wrote: >> From: Muchun Song >> >> In the near future, a folio will no longer pin its corresponding >> memory cgroup. So an lruvec returned by folio_lruvec() could be >> released without the rcu read lock or a reference to its memory >> cgroup. >> >> In the current patch, the rcu read lock is employed to safeguard >> against the release of the lruvec in lru_note_cost_refault() and >> lru_activate(). > > nit: the above paragraph looks incorrect. Right, will fix it in the version. > >> This serves as a preparatory measure for the reparenting of the >> LRU pages. >> >> Signed-off-by: Muchun Song >> Signed-off-by: Qi Zheng >> --- > > Looks good to me, > Reviewed-by: Harry Yoo Thanks! >