Skip to contentSkip to conversation

f2fs: preallocate blocks for encrypted file

RFC PATCH Superseded Yunlei He 2 participants 2 messages Sep 14, 2016 F2FS file system

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Yunlei He

author
#0 lore raw

RFC PATCH 1/1 f2fs: preallocate blocks for encrypted file

This patch allow preallocates data blocks for buffered aio writes in encrypted file.

---
 fs/f2fs/data.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/data.c +0 -3
index 3e0ef2d..529e9a2 100644
@@ -639,9 +639,6 @@ ssize_t f2fs_preallocate_blocks(struct kiocb *iocb, struct iov_iter *from)
 
 	map.m_next_pgofs = NULL;
 
-	if (f2fs_encrypted_inode(inode))
-		return 0;
-
 	if (iocb->ki_flags & IOCB_DIRECT) {
 		ret = f2fs_convert_inline_inode(inode);
 		if (ret)
Signature · 4 lines
1.9.1


------------------------------------------------------------------------------
maintainer
#1 lore raw
Quoted 13 lines · Yunlei He

This patch allow preallocates data blocks for buffered aio writes in encrypted file.

---
 fs/f2fs/data.c | 3 ---
 1 file changed, 3 deletions(-)
fs/f2fs/data.c +0 -0
index 3e0ef2d..529e9a2 100644

fs/f2fs/data.c ssize_t f2fs_preallocate_blocks(struct kiocb *iocb, struct iov_iter *from) · line 644

Quoted 6 lines
fs/f2fs/data.c +0 -3
@@ -639,9 +639,6 @@ ssize_t f2fs_preallocate_blocks(struct kiocb *iocb, struct iov_iter *from)
 
 	map.m_next_pgofs = NULL;
 
-	if (f2fs_encrypted_inode(inode))
-		return 0;
-

Then, it needs to remove the condition in prepare_write_begin() as well.

Thanks,

Quoted 12 lines
fs/f2fs/data.c +0 -0
 	if (iocb->ki_flags & IOCB_DIRECT) {
 		ret = f2fs_convert_inline_inode(inode);
 		if (ret)
Signature · 8 lines
1.9.1


------------------------------------------------------------------------------
_______________________________________________
Linux-f2fs-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel

------------------------------------------------------------------------------