Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756226AbdLVOno (ORCPT ); Fri, 22 Dec 2017 09:43:44 -0500 Received: from mail-io0-f176.google.com ([209.85.223.176]:33654 "EHLO mail-io0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756020AbdLVOnm (ORCPT ); Fri, 22 Dec 2017 09:43:42 -0500 X-Google-Smtp-Source: ACJfBosROEh8pyddrKkpyNwCB3vwk5kaEipA1acgpUVLDPopINU56t1jKNdvukBWJKbZKYLaFoFphg== Subject: (Lack of) i_version handling in udf To: Jan Kara Cc: Jeff Layton , linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org References: <20171222120556.7435-1-jlayton@kernel.org> From: Steve Magnani Message-ID: <19f848dd-aa94-70bc-73b2-4c1d8b352636@digidescorp.com> Date: Fri, 22 Dec 2017 08:43:40 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: <20171222120556.7435-1-jlayton@kernel.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1834 Lines: 40 Jan, Re: [PATCH v4 00/19] fs: rework and optimize i_version handling in filesystems On 12/22/2017 06:05 AM, Jeff Layton wrote: > The inode->i_version field is supposed to be a value that changes > whenever there is any data or metadata change to the inode. Some > filesystems use it internally to detect directory changes during > readdir. knfsd will use it if the filesystem has MS_I_VERSION set. IMA > will also use it to optimize away some remeasurement if it's available. > NFS and AFS just use it to store an opaque change attribute from the > server. > > Only btrfs, ext4, and xfs increment it for data changes. Because of > this, these filesystems must log the inode to disk whenever the > i_version counter changes. That has a non-zero performance impact, > especially on write-heavy workloads, because we end up dirtying the > inode metadata on every write, not just when the times change. > > It turns out though that none of these users of i_version require that > it change on every change to the file. The only real requirement is that > it be different if something changed since the last time we queried for > it. > > If we keep track of when something queries the value, we can avoid > bumping the counter and an on-disk update when nothing else has changed > if no one has queried it since it was last incremented. This happened to cross my radar, which made me think...is it a problem that the UDF driver does not have any references to i_version at all? I suppose R/W UDF is a small subset of the normal use cases, but the driver does try to support it. Regards, ------------------------------------------------------------------------ Steven J. Magnani "I claim this network for MARS! www.digidescorp.com Earthling, return my space modulator!" #include