aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ecryptfs/read_write.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/ecryptfs/read_write.c')
-rw-r--r--fs/ecryptfs/read_write.c22
1 files changed, 0 insertions, 22 deletions
diff --git a/fs/ecryptfs/read_write.c b/fs/ecryptfs/read_write.c
index ebf55150be56..75c2ea9fee35 100644
--- a/fs/ecryptfs/read_write.c
+++ b/fs/ecryptfs/read_write.c
@@ -157,20 +157,6 @@ int ecryptfs_write(struct file *ecryptfs_file, char *data, loff_t offset,
157 ecryptfs_page_idx, rc); 157 ecryptfs_page_idx, rc);
158 goto out; 158 goto out;
159 } 159 }
160 if (start_offset_in_page) {
161 /* Read in the page from the lower
162 * into the eCryptfs inode page cache,
163 * decrypting */
164 rc = ecryptfs_decrypt_page(ecryptfs_page);
165 if (rc) {
166 printk(KERN_ERR "%s: Error decrypting "
167 "page; rc = [%d]\n",
168 __func__, rc);
169 ClearPageUptodate(ecryptfs_page);
170 page_cache_release(ecryptfs_page);
171 goto out;
172 }
173 }
174 ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0); 160 ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0);
175 161
176 /* 162 /*
@@ -349,14 +335,6 @@ int ecryptfs_read(char *data, loff_t offset, size_t size,
349 ecryptfs_page_idx, rc); 335 ecryptfs_page_idx, rc);
350 goto out; 336 goto out;
351 } 337 }
352 rc = ecryptfs_decrypt_page(ecryptfs_page);
353 if (rc) {
354 printk(KERN_ERR "%s: Error decrypting "
355 "page; rc = [%d]\n", __func__, rc);
356 ClearPageUptodate(ecryptfs_page);
357 page_cache_release(ecryptfs_page);
358 goto out;
359 }
360 ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0); 338 ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0);
361 memcpy((data + data_offset), 339 memcpy((data + data_offset),
362 ((char *)ecryptfs_page_virt + start_offset_in_page), 340 ((char *)ecryptfs_page_virt + start_offset_in_page),