* [PATCH 17/22] ncpfs: drop vmtruncate
@ 2012-10-06 8:33 Marco Stornelli
2012-10-13 16:23 ` Christoph Hellwig
0 siblings, 1 reply; 2+ messages in thread
From: Marco Stornelli @ 2012-10-06 8:33 UTC (permalink / raw)
To: Al Viro
Cc: Petr Vandrovec, Anton Blanchard, Benjamin Herrenschmidt,
linux-kernel, Linux FS Devel
Removed vmtruncate.
Signed-off-by: Marco Stornelli <marco.stornelli@gmail.com>
---
fs/ncpfs/inode.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/fs/ncpfs/inode.c b/fs/ncpfs/inode.c
index d7e9fe7..b6881aa 100644
--- a/fs/ncpfs/inode.c
+++ b/fs/ncpfs/inode.c
@@ -976,9 +976,11 @@ int ncp_notify_change(struct dentry *dentry, struct iattr *attr)
goto out;
if (attr->ia_size != i_size_read(inode)) {
- result = vmtruncate(inode, attr->ia_size);
+ result = inode_newsize_ok(inode, attr->ia_size);
if (result)
goto out;
+
+ truncate_setsize(inode, attr->ia_size);
mark_inode_dirty(inode);
}
}
--
1.7.3.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 17/22] ncpfs: drop vmtruncate
2012-10-06 8:33 [PATCH 17/22] ncpfs: drop vmtruncate Marco Stornelli
@ 2012-10-13 16:23 ` Christoph Hellwig
0 siblings, 0 replies; 2+ messages in thread
From: Christoph Hellwig @ 2012-10-13 16:23 UTC (permalink / raw)
To: Marco Stornelli
Cc: Al Viro, Petr Vandrovec, Anton Blanchard, Benjamin Herrenschmidt,
linux-kernel, Linux FS Devel
> if (attr->ia_size != i_size_read(inode)) {
> - result = vmtruncate(inode, attr->ia_size);
> + result = inode_newsize_ok(inode, attr->ia_size);
> if (result)
> goto out;
> +
> + truncate_setsize(inode, attr->ia_size);
> mark_inode_dirty(inode);
inode_newsize_ok already is done as part of inode_change_ok earlier on.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2012-10-13 16:23 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-10-06 8:33 [PATCH 17/22] ncpfs: drop vmtruncate Marco Stornelli
2012-10-13 16:23 ` Christoph Hellwig
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).