linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/2] vfs: truncate bug fixes
@ 2011-12-22  8:55 Dmitry Kasatkin
  2011-12-22  8:55 ` [PATCH v2 1/2] vfs: iversion truncate bug fix Dmitry Kasatkin
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Dmitry Kasatkin @ 2011-12-22  8:55 UTC (permalink / raw)
  To: linux-fsdevel, linux-security-module; +Cc: akpm, viro, linux-kernel, zohar

When a file is opened with O_TRUNC or truncated with truncate()/ftruncate(),
and then closed, iversion is not updated. This patch uses ATTR_OPEN flag,
which is currently used to identify files opened with O_TRUNC,
as an indication to increment iversion.
Also it adds passing of this flag from do_sys_truncate and do_sys_ftruncate.
To reflect real meaning, ATTR_OPEN is suggested to be renamed to ATTR_TRUNC.

Dmitry Kasatkin (2):
  vfs: iversion truncate bug fix
  vfs: ATTR_OPEN rename

 fs/attr.c          |    3 +++
 fs/fuse/dir.c      |    4 ++--
 fs/namei.c         |    2 +-
 fs/open.c          |    5 +++--
 include/linux/fs.h |    2 +-
 5 files changed, 10 insertions(+), 6 deletions(-)

-- 
1.7.4.1


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-12-22 10:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-12-22  8:55 [PATCH v2 0/2] vfs: truncate bug fixes Dmitry Kasatkin
2011-12-22  8:55 ` [PATCH v2 1/2] vfs: iversion truncate bug fix Dmitry Kasatkin
2011-12-22  8:55 ` [PATCH v2 2/2] vfs: ATTR_OPEN rename Dmitry Kasatkin
2011-12-22  9:10 ` [PATCH v2 0/2] vfs: truncate bug fixes Al Viro
2011-12-22 10:29   ` Kasatkin, Dmitry

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).