All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heinrich Schuchardt <xypron.glpk@gmx.de>
To: Jan Kara <jack@suse.cz>
Cc: Christoph Hellwig <hch@infradead.org>,
	Eric Paris <eparis@parisplace.org>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>,
	Jeff Layton <jlayton@poochiereds.net>,
	"J. Bruce Fields" <bfields@fieldses.org>,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2 1/1] ftruncate, truncate: create fanotify events
Date: Fri, 14 Nov 2014 22:30:40 +0100	[thread overview]
Message-ID: <54667480.2040703@gmx.de> (raw)
In-Reply-To: <20141114100135.GB17262@quack.suse.cz>

Hello Jan,

thank you for the review.

On 14.11.2014 11:01, Jan Kara wrote:
>>
>> We only want to create FAN_MODIFY events for ATTR_SIZE. So only for
>> these events we need a path.
>>
>> To my knowledge notify_change is called with ATTR_SIZE from
>> do_truncate(), ecryptfs_truncate() and will be called with ATTR_SIZE
>> from ovl_setattr() for a truncation.
>    There's also a call in fs/cachefiles/interface.c: cachefiles_attr_changed()
> and fs/hpfs/namei.c: hpfs_unlink() and nfs plays with ATTR_SIZE although I
> wasn't able to track down whether it actually passes it to notify_change().

cachefiles_attr_changed() contains two calls to notify_change(). Both 
calls pass ATTR_SIZE as sole attribute.

In cachefiles_attr_changed() we can create a path object with
path.dentry = object->backer;
path.mnt = cache->mnt;

In hpfs_unlink() a truncation occurs only if deletion fails.
I do not see how to access a path here.

notify_change() is not called in directory fs/nfs.
grep -GHrn notify_change fs/nfs/
This does not test for any indirect call.

Best regards

Heinrich Schuchardt

      reply	other threads:[~2014-11-14 21:30 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-10-03 18:16 [PATCH 1/1] ftruncate: create FAN_MODIFY and IN_MODIFY events Heinrich Schuchardt
2014-10-06 13:24 ` Jan Kara
2014-10-06 20:09   ` Heinrich Schuchardt
2014-10-07 19:23     ` Jan Kara
2014-10-23 21:35       ` [PATCH v2 1/1] ftruncate, truncate: create fanotify events Heinrich Schuchardt
2014-11-10 20:30         ` Jan Kara
2014-11-10 23:10           ` Heinrich Schuchardt
2014-11-11  7:34           ` Christoph Hellwig
2014-11-11 11:09             ` Jan Kara
2014-11-11 19:55               ` Heinrich Schuchardt
2014-11-14 10:01                 ` Jan Kara
2014-11-14 21:30                   ` Heinrich Schuchardt [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=54667480.2040703@gmx.de \
    --to=xypron.glpk@gmx.de \
    --cc=bfields@fieldses.org \
    --cc=eparis@parisplace.org \
    --cc=hch@infradead.org \
    --cc=hirofumi@mail.parknet.co.jp \
    --cc=jack@suse.cz \
    --cc=jlayton@poochiereds.net \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.