Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp670528pxk; Wed, 16 Sep 2020 13:59:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwnxVX/vxtrum9urMLsa12NwJIfZEhMwdZUviqpVeIzWmQszixFxq4UsnFjiqRl0/aa9i3c X-Received: by 2002:a05:6402:1b0f:: with SMTP id by15mr28847501edb.289.1600289963281; Wed, 16 Sep 2020 13:59:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600289963; cv=none; d=google.com; s=arc-20160816; b=tDcBftEOXBNpc4gbD0gfIV9tCzO4sz5RRqbfwBBy5Tqu5vVXBRYl50bviEqvykh/Ri ULwlSkTyeSiHZzoGjF10KxnIx074UeyQffuyas8mF4eP4OsH4pEHVe/TgVse0uyC2v6j MO860FerABCNY9W3K5s7WnIUh6YZDVkAndeSzBS1p2HCkxBRF8c+uf99pm3nOZSHn1fI rZYegDdc6QkF0l2Smv0srelh5CukXIBjCTohsmnLLVALtZvFnbfm/xM5uGQioAqBtmZB 8rrLoFMydiYgxhE5rosd1EmftE5uBuxPb2Zc9o42NGhF1IKNoK6wvhJgbDQpYPNtIB4B dj4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=M9ybc7xxT3uVOtOy2YaXXBTz09w2w4dOhA355aJSKs8=; b=XlRTzbnT54r5I571+e26IRuOfuI54mByJp8XAj38ZbD4pKUd1sz3QwRLy4uNJQeMiI jf96hQGQef3nQitQyUSKXK8ETCgHaX8KL9/68U6aN7Throlew0Vch+EVICPEewJM5Tvm kndzI2RHu6rk0WqkRGuKB2V+AggniY11NwN60ZDySt040aczSJMztz3UB9smtccMXQUT E9KpfHc/Te58ghv4BoTBMj1KvA8KsL2wmJ5MvT41wUILWntYfYBknT7l3BG6OHL9amkz u6/0kF9YIxsQLMGanldtKztJ9nJOC57ZVh1jAGPw4NYY0c6dg4FboDeMT1euggUqx4oa 4Ieg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h12si4523544ejx.608.2020.09.16.13.58.59; Wed, 16 Sep 2020 13:59:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726148AbgIPU5B (ORCPT + 99 others); Wed, 16 Sep 2020 16:57:01 -0400 Received: from mx2.suse.de ([195.135.220.15]:43644 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726558AbgIPQwi (ORCPT ); Wed, 16 Sep 2020 12:52:38 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id 5EB0CABD1; Wed, 16 Sep 2020 16:52:52 +0000 (UTC) Received: by quack2.suse.cz (Postfix, from userid 1000) id C2A631E12E1; Wed, 16 Sep 2020 18:52:36 +0200 (CEST) Date: Wed, 16 Sep 2020 18:52:36 +0200 From: Jan Kara To: Mauricio Faria de Oliveira Cc: Jan Kara , linux-ext4@vger.kernel.org, dann frazier , Mauricio Faria de Oliveira Subject: Re: [RFC PATCH v3 2/3] jbd2, ext4, ocfs2: introduce/use journal callbacks j_submit|finish_inode_data_buffers() Message-ID: <20200916165236.GN3607@quack2.suse.cz> References: <20200910193127.276214-1-mfo@canonical.com> <20200910193127.276214-3-mfo@canonical.com> <20200916162240.GM3607@quack2.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200916162240.GM3607@quack2.suse.cz> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Wed 16-09-20 18:22:40, Jan Kara wrote: > On Thu 10-09-20 16:31:26, Mauricio Faria de Oliveira wrote: > > @@ -1111,6 +1113,27 @@ struct journal_s > > void (*j_commit_callback)(journal_t *, > > transaction_t *); > > > > + /** > > + * @j_submit_inode_data_buffers: > > + * > > + * This function is called for all inodes associated with the > > + * committing transaction marked with JI_WRITE_DATA flag > > + * before we start to write out the transaction to the journal. > > + */ > > + int (*j_submit_inode_data_buffers) > > + (struct jbd2_inode *); > > + > > + /** > > + * @j_finish_inode_data_buffers: > > + * > > + * This function is called for all inodes associated with the > > + * committing transaction marked with JI_WAIT_DATA flag > > + * after we have written the transaction to the journal > > + * but before we write out the commit block. > > + */ > > + int (*j_finish_inode_data_buffers) > > + (struct jbd2_inode *); > > + > > Having the callbacks in the journal_s will not work if we have inodes with > data journalling on a filesystem mounted in data=ordered mode. The > callbacks really need to be a per-inode thing so I'd add them to struct > jbd2_inode. Oh, now I see that you properly handle this in the callbacks. So I retract this objection. So feel free to add: Reviewed-by: Jan Kara after removing those pointless wrappers. Hoonza -- Jan Kara SUSE Labs, CR