Received: by 2002:a05:7412:d1aa:b0:fc:a2b0:25d7 with SMTP id ba42csp1658891rdb; Wed, 31 Jan 2024 05:35:04 -0800 (PST) X-Google-Smtp-Source: AGHT+IEeiKlDRYrlMtKfwgc0pLqWV8fYpHAE2BcgkJXv32j6UQokhxruUUL6jA8DnS2rguJYFJRe X-Received: by 2002:a05:6358:721:b0:176:5b4f:492b with SMTP id e33-20020a056358072100b001765b4f492bmr1658151rwj.12.1706708104165; Wed, 31 Jan 2024 05:35:04 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706708104; cv=pass; d=google.com; s=arc-20160816; b=eV7Ijoo0LhBtdgDuyOkjwDeWilaUkEuTaH2+ii+nVs/Fu96I66RT7oYtW11R0Sc4Di 6rs8aoExaN5xc4bxphhep9iirsVhIq2CJAlxf5typIMBV7H0H+xs3p//Fynzluq9qs4y QCdRBsYRW9APuEKt0jUkX8C4xQofV9/QMZwKyrBdwitnz1VQvCrIWYuq3rOwgyaHNQWw MHfKzaiaKjFTUEZiD3rsW3Wk6fqzzEejyziGweu2OZXCejzAuGUajP9uBFgRvFcoqCH1 U0uBPlGxklra4JRGKGTBlwyKIKpQLbrAdMZyLj7tpAtHEbPtXjkq3tGefZ1n7BI0KZm2 QsAQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date; bh=ukCodLzb/G2VLqiQlvaxDGyFzovgifaCzLn8v5k78fs=; fh=VVfC8Kw6NrllgnDCVD/nxiUJkaHCkByTA8jMAXSDynU=; b=sJHkry00uTQEzTyRbhA4R3poOVlL1RLI0Fq/ai7kaqiIk0xYl4sU1o+Lhxg3FL9ciW bgeXLAPDGSFc1jht0wxwfiNaskgjMGb7MphNcwNhIaWSvmmepi3tLNw1v3MOWh2EqJ1P XARBm+3vB49MmArDyTZXZj/+FhYUosjnkvNJkXjMR3jMwBz2Kd1WGwqAocVZ+Cu9CVAD E7+04mA9Xhf3AebC3J8QdoVecPe2L58trfre9G1WVzIYrtCPqgV47YXMmdp9+vm/Jeg9 DcHq88uuH32ChzeEtsO2US7ReV7CrtWbovnYWQQicK83YgdtC/JkdvscUHCEASn9QrP/ Xdvw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=lst.de); spf=pass (google.com: domain of linux-kernel+bounces-46456-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-46456-linux.lists.archive=gmail.com@vger.kernel.org" X-Forwarded-Encrypted: i=1; AJvYcCUp8nrQVXexE6IWQtSWShvbG8EVnYYt+nKXbXuDG9nTp/3Z+j5I5GbKExmvRVxt0bxp+6rV82sg8c30kIILzaeFrxnxg6QEiUGz6R68zQ== Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id z67-20020a633346000000b005d8e379746fsi3375821pgz.469.2024.01.31.05.35.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 31 Jan 2024 05:35:04 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-46456-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=lst.de); spf=pass (google.com: domain of linux-kernel+bounces-46456-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-46456-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 80CC9B2E0B9 for ; Wed, 31 Jan 2024 13:02:04 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 782A67BAE5; Wed, 31 Jan 2024 13:01:43 +0000 (UTC) Received: from verein.lst.de (verein.lst.de [213.95.11.211]) (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 7243F7A716; Wed, 31 Jan 2024 13:01:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.95.11.211 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706706103; cv=none; b=YZfXwGHDsrE4tJ54pXP7ExG01MsbGijNPp6b1iIYmMUnXiZyhLt+jz3qpOakjvjA6uNKUi2j/A/pHpCJS2fe/1iYgFOKkWbgahAaH9kfvJuNBS8fHseJad36PRLVH8IY9huGb/4a0XxjxbTWXHf1V7le5VJ7Ep55XepsbzzT3lI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706706103; c=relaxed/simple; bh=A2HkjWs/uqyXRaWNFEgz3xTTLEQ3Q1Ks7F/RFXEiUUc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=RFU+SNOdM2bb0tbVTZmRKuJSA/oDF1HF1C8DvouYYPFBi6/P7SjHehnLbraN59OIez8Q6PhPNhWS8L4S1yxsRu9qOvNPePZSCbbzMRqyWCNKLRbZrIHIVUYXraShw5epX6KowaMa4UtuJuQgZCZr7STdzLrX5T+hAcFauqjXyz4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de; spf=pass smtp.mailfrom=lst.de; arc=none smtp.client-ip=213.95.11.211 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lst.de Received: by verein.lst.de (Postfix, from userid 2407) id AEAFC68BEB; Wed, 31 Jan 2024 14:01:33 +0100 (CET) Date: Wed, 31 Jan 2024 14:01:33 +0100 From: Christoph Hellwig To: Brian Foster Cc: Christoph Hellwig , Jan Kara , linux-mm@kvack.org, Matthew Wilcox , Jan Kara , David Howells , Christian Brauner , "Darrick J. Wong" , linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 19/19] writeback: simplify writeback iteration Message-ID: <20240131130133.GA25391@lst.de> References: <20240125085758.2393327-1-hch@lst.de> <20240125085758.2393327-20-hch@lst.de> <20240130104605.2i6mmdncuhwwwfin@quack3> <20240130141601.GA31330@lst.de> <20240130215016.npofgza5nmoxuw6m@quack3> <20240131071437.GA17336@lst.de> 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: User-Agent: Mutt/1.5.17 (2007-11-01) On Wed, Jan 31, 2024 at 07:50:25AM -0500, Brian Foster wrote: > The implied field initialization via !folio feels a little wonky to me > just because it's not clear from the client code that both fields must > be initialized. Even though the interface is simpler, I wonder if it's > still worth having a dumb/macro type init function that at least does > the batch and error field initialization. > > Or on second thought maybe having writeback_iter() reset *error as well > on folio == NULL might be a little cleaner without changing the > interface.... I like that second idea. An initialization helper I could live with, but if only folio needs a defined state, that seems superflous.