|
@@ -157,20 +157,6 @@ int ecryptfs_write(struct file *ecryptfs_file, char *data, loff_t offset,
|
|
|
ecryptfs_page_idx, rc);
|
|
|
goto out;
|
|
|
}
|
|
|
- if (start_offset_in_page) {
|
|
|
- /* Read in the page from the lower
|
|
|
- * into the eCryptfs inode page cache,
|
|
|
- * decrypting */
|
|
|
- rc = ecryptfs_decrypt_page(ecryptfs_page);
|
|
|
- if (rc) {
|
|
|
- printk(KERN_ERR "%s: Error decrypting "
|
|
|
- "page; rc = [%d]\n",
|
|
|
- __func__, rc);
|
|
|
- ClearPageUptodate(ecryptfs_page);
|
|
|
- page_cache_release(ecryptfs_page);
|
|
|
- goto out;
|
|
|
- }
|
|
|
- }
|
|
|
ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0);
|
|
|
|
|
|
/*
|
|
@@ -349,14 +335,6 @@ int ecryptfs_read(char *data, loff_t offset, size_t size,
|
|
|
ecryptfs_page_idx, rc);
|
|
|
goto out;
|
|
|
}
|
|
|
- rc = ecryptfs_decrypt_page(ecryptfs_page);
|
|
|
- if (rc) {
|
|
|
- printk(KERN_ERR "%s: Error decrypting "
|
|
|
- "page; rc = [%d]\n", __func__, rc);
|
|
|
- ClearPageUptodate(ecryptfs_page);
|
|
|
- page_cache_release(ecryptfs_page);
|
|
|
- goto out;
|
|
|
- }
|
|
|
ecryptfs_page_virt = kmap_atomic(ecryptfs_page, KM_USER0);
|
|
|
memcpy((data + data_offset),
|
|
|
((char *)ecryptfs_page_virt + start_offset_in_page),
|