(), and ecryptfs_copy_up_encrypted_with_header()
should have the responsibility of managing the page Uptodate
status. This patch gets rid of some of the ugliness that resulted from
trying to push some of the page flag setting too far down the stack.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
diff --git a/fs/ecryptfs/crypto.c b/fs
and perhaps the whole fs for this easy-to-do,
hard-to-find bug.
Update data types and add casts in order to avoid potential overflow
issues.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
diff --git a/fs/ecryptfs/crypto.c b/fs/ecryptfs/crypto.c
index 5d27cf9..4bf1a95 100644
--- a/fs/ecryptfs/crypto.c
On Wed, Sep 19, 2007 at 10:48:17PM -0700, Andrew Morton wrote:
On Mon, 17 Sep 2007 16:48:44 -0500 Michael Halcrow [EMAIL PROTECTED] wrote:
+ if ((rc = ecryptfs_write_lower(ecryptfs_dentry-d_inode,
checkpatch missed the assignment-in-an-if here.
Fix an assignment-in-an-if.
Signed
://lkml.org/lkml/2007/9/15/55
In order to avoid this possibility, eCryptfs must allocate an
intermediate block of memory to use with vfs_read() and vfs_write(),
copying the data through this memory region, since kmap_atomic()
cannot be held during calls which may block.
Signed-off-by: Michael Halcrow
On Wed, Sep 19, 2007 at 10:46:26PM -0700, Andrew Morton wrote:
(from ecryptfs_encrypt_page()):
+ enc_extent_virt = kmalloc(PAGE_CACHE_SIZE, GFP_USER);
I'd have thought that alloc_page() would be nicer. After all, we _are_
treating it as a page, and not as a random piece of memry.
+
On Wed, Sep 19, 2007 at 10:50:57PM -0700, Andrew Morton wrote:
On Mon, 17 Sep 2007 16:50:16 -0500 Michael Halcrow [EMAIL PROTECTED] wrote:
+ecryptfs_copy_up_encrypted_with_header(struct page *page,
+ struct ecryptfs_crypt_stat *crypt_stat
Currently, eCryptfs directly accesses the lower inode address space,
doing things like grab_cache_page() on lower_inode-i_mapping. It
really should not do that. The main point of this patch set is to make
all I/O with the lower files go through vfs_read() and vfs_write()
instead.
In order to
There is no point to keeping a separate header_extent_size and an
extent_size. The total size of the header can always be represented as
some multiple of the regular data extent size.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c | 40
Remove assignments in if-statements.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c| 17 --
fs/ecryptfs/file.c |8 --
fs/ecryptfs/inode.c | 35 ++
fs/ecryptfs/keystore.c | 55
. For now, in order to keep from breaking the build, I am
putting dummy parameters in for those functions.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/Makefile |2 +-
fs/ecryptfs/ecryptfs_kernel.h | 18 ++
fs/ecryptfs/mmap.c|2 +-
fs/ecryptfs
Replace page encryption and decryption routines and inode size write
routine with versions that utilize the read_write.c functions.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c | 427 ++--
fs/ecryptfs/ecryptfs_kernel.h
This patch sets up and destroys the persistent lower file for each
eCryptfs inode.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/inode.c | 23 +++---
fs/ecryptfs/main.c | 65 +++
fs/ecryptfs/super.c | 22
the eCryptfs getxattr.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c | 126 +++--
fs/ecryptfs/ecryptfs_kernel.h | 15 +++--
fs/ecryptfs/file.c|2 +-
fs/ecryptfs/inode.c | 101
.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c |2 +-
fs/ecryptfs/file.c | 50 --
fs/ecryptfs/inode.c | 113 +++---
3 files changed, 44 insertions(+), 121 deletions(-)
diff --git a/fs/ecryptfs
Convert readpage, prepare_write, and commit_write to use read_write.c
routines. Remove sync_page; I cannot think of a good reason for
implementing that in eCryptfs.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/mmap.c | 199
Initialize persistent lower file on inode create.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/super.c | 13 +++--
1 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/fs/ecryptfs/super.c b/fs/ecryptfs/super.c
index b97e210..f8cdab2 100644
--- a/fs
The switch to read_write.c routines and the persistent file make a
number of functions unnecessary. This patch removes them.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c | 150 --
fs/ecryptfs/ecryptfs_kernel.h | 21 +---
fs/ecryptfs/file.c
Replace some magic numbers with sizeof() equivalents.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
---
fs/ecryptfs/crypto.c |6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/fs/ecryptfs/crypto.c b/fs/ecryptfs/crypto.c
index 3b3cf27..425a144 100644
--- a/fs
Delay writing 0's out in eCryptfs after a seek past the end of the
file until data is actually written.
Signed-off-by: Michael Halcrow [EMAIL PROTECTED]
diff --git a/fs/ecryptfs/file.c b/fs/ecryptfs/file.c
index 9881b5c..59288d8 100644
--- a/fs/ecryptfs/file.c
+++ b/fs/ecryptfs/file.c
On Mon, Jan 08, 2007 at 03:51:31PM -0500, Erez Zadok wrote:
BTW, this is a problem with all stackable file systems, including
ecryptfs. To be fair, our Unionfs users have come up against this
problem, usually for the first time they use Unionfs :-).
I suspect that the only reason why this has
20 matches
Mail list logo