From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-qk1-f169.google.com (mail-qk1-f169.google.com [209.85.222.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5C4E43563F6 for ; Tue, 17 Mar 2026 14:34:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.222.169 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773758058; cv=none; b=ROpM42bxnlRqaSGSwC3r/UEGEQlYunTZtKo2lyVKtJ+i9mnG256kwdWtWthWBfmJF/sE/cbZwwljL9STsDLJ1VgrzB4tMQPXM2+Od/oMFL5onsaQ52Z7fHH2yH4cgNmpxy/hMtK3WSkdRa5EaSbPQQrYOSX3gH/JluUgLKEK2o0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1773758058; c=relaxed/simple; bh=gA4+8fZH3/R4FKVjfBCgkwygr4A0Uqxq20eGzIPE5co=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=seVrccPyYGL22l7Hlui2aDJAAC/Pxb+LRmzeZR4DaMXaNKVG9dfPYlIcshTY2/JLuZIgU1ARrP3wXalZSuEgdRps3ozoPpZLOEZr/1wLyVERq5r/oQ3EYewFLsJ1RHm0ZFyoqWlyo1//fsOZ5Lj/8zIrxR+oIdGdJeXF8GlnuK8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=cmpxchg.org; spf=pass smtp.mailfrom=cmpxchg.org; dkim=pass (2048-bit key) header.d=cmpxchg.org header.i=@cmpxchg.org header.b=spxIkttL; arc=none smtp.client-ip=209.85.222.169 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=cmpxchg.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=cmpxchg.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=cmpxchg.org header.i=@cmpxchg.org header.b="spxIkttL" Received: by mail-qk1-f169.google.com with SMTP id af79cd13be357-8cb20bcff5aso582699485a.3 for ; Tue, 17 Mar 2026 07:34:15 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=cmpxchg.org; s=google; t=1773758055; x=1774362855; darn=vger.kernel.org; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=mnjxrzOC3v6uWzLnI6ltEx0aufj32t/PG4nGWr54wv4=; b=spxIkttL8oXEa+bvhH6vHnJDa1kKpxaCHMx8PVWg3ohQ0YJnu3d3MJyaJxVGlEOVC2 86hPDA4752Wx5bgQ+RryBB+sny4+pyjBcMzzg/4zWckGCWljMWrOOsqp8gb58Hi9b/nM +LTp+Tk6Mv40Laa8roBGRQmXwbUB17qp14trewa8iNEvgroAnhhtGcTh8z0q6QyVuVc9 3pEkwtnwplp8S5pqc5ML/11gLFYPyIaGoo0OSz8Fwkb23xxCP79yVlHpKbt1wD8p05xz AO+Nl4O19jF5uBpGp+Z3Fc+P6mMJDDK9EV68NMeg///APvYTfneBOOLLYT9jSZuA3RhD 3VwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1773758055; x=1774362855; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-gg:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=mnjxrzOC3v6uWzLnI6ltEx0aufj32t/PG4nGWr54wv4=; b=cNKG+WqseGuKttxV4aFtqLU8rnD3QmvmTmUxPaQJfLTVDeJgwO9SvNQR/RjU+V8jDL hsf+Q43FQeqJ9an2nYNmrBvcA35w7etEiiKMrAmMbJoaCTuwyOd75X8JNnC4+Wl8u7tt whzoTO1djztxUumvDiEZRP62yPNrSHa44rTBZdnLbngdU9ASML1sNm9KYimb7nwKHhce +Z/+ojz3vPnTqAaf4v1y2RneMDTwFjACur4Jh2QNg0p49f0xhw/QZAYDqbPGIwMLoUNn uI11gOf7hqecibMyIkQtDDW+Rch8dI6pBOb5ix6uNL2FFHXENDQDDr99RhyhF/zGkdNG J+mA== X-Forwarded-Encrypted: i=1; AJvYcCX/32Ggefao6n0ivu6BXDp1aZLO1NEUUrmRPrA6Hd6lDA1toRfxosJGmjS7tGp5QdGGNlZJRXiLD+a77h8=@vger.kernel.org X-Gm-Message-State: AOJu0Yx/INyDynLEg1/QD6ldhbD2ONII6BbrGOTv49QIJpwQUPz5Zof0 eLg83QDGOW37W5Fr19PkA/MykfD5HVr/td5SgOzD69JJ5Fnjye0WuyFq+/rKg9jz5lg= X-Gm-Gg: ATEYQzyZiKZRGZ345Dl9Qs4BgmFhxsxjH7XgkhMOLQvHfBOwtaIQvNmKH/gbApl8cYE IvJfCTakrT0S+xZT7Vc49UwOnxgeAPpo4qkfb+9M7Mgeyypi4alNBMEcDIk6tLeZJJp5S6am77s HfcmFALOAPHrE9qJMijIMu+V8awpPIWsUcSb9Xjzm5zRNaBb3L6QvK5I40lYLThJnThRtVBrK/A b6XmOd+DUNkzs3eEs7lieU+IR5ziSnDHj2kvbMAYAfI/vWEuDcRb+asVwM8w+sNTlSw9g7YqUQd 0yQhs2+aFvhWmKv/eE/W5pGsgCCkeOj/djYHr3Y66ZdzbRyXCEr1ENPSI8vfZl5dt1o76+k25dL S6sHziu82xS4gbr0QSxi/NrXcBrwx1C+dyf3NJiWKYb9+f/D/utMjZaX5kDQrtjnqImTJk3anfN 5b2Fme6FHMnCBDruJZeqYfNw== X-Received: by 2002:a05:6214:d69:b0:895:4b79:83a4 with SMTP id 6a1803df08f44-89a81c89e4cmr226468216d6.4.1773758054904; Tue, 17 Mar 2026 07:34:14 -0700 (PDT) Received: from localhost ([2603:7000:c00:3a00:365a:60ff:fe62:ff29]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-89c4feaaebasm48948496d6.37.2026.03.17.07.34.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 17 Mar 2026 07:34:14 -0700 (PDT) Date: Tue, 17 Mar 2026 10:34:10 -0400 From: Johannes Weiner To: "David Hildenbrand (Arm)" Cc: Andrew Morton , Shakeel Butt , Yosry Ahmed , Zi Yan , "Liam R. Howlett" , Usama Arif , Kiryl Shutsemau , Dave Chinner , Roman Gushchin , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 5/7] mm: list_lru: introduce caller locking for additions and deletions Message-ID: References: <20260312205321.638053-1-hannes@cmpxchg.org> <20260312205321.638053-6-hannes@cmpxchg.org> <46d9173e-98cd-4f59-b0f3-e477afd5283b@kernel.org> 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=us-ascii Content-Disposition: inline In-Reply-To: On Tue, Mar 17, 2026 at 10:03:08AM -0400, Johannes Weiner wrote: > On Tue, Mar 17, 2026 at 11:00:59AM +0100, David Hildenbrand (Arm) wrote: > > On 3/12/26 21:51, Johannes Weiner wrote: > > > +void list_lru_unlock(struct list_lru_one *l) > > > +{ > > > + unlock_list_lru(l, false, NULL); > > > +} > > > + > > > +struct list_lru_one *list_lru_lock_irqsave(struct list_lru *lru, int nid, > > > + struct mem_cgroup *memcg, > > > + unsigned long *flags) > > > +{ > > > + return lock_list_lru_of_memcg(lru, nid, memcg, true, flags, false); > > > > And here it gets really confusing. true false false ... am I reading > > binary code? > > > > I guess the second "false" should actually be "NULL" :) > > Good catch, I'll fix that. That's actually "flags" haha. But it supports your point.