f2fs: fix an error return value in truncate_partial_data_page
PATCH 1/1 f2fs: fix an error return value in truncate_partial_data_page
This patch fix a error return value in truncate_partial_data_page
--- fs/f2fs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/file.c +1 -1
@@ -529,7 +529,7 @@ static int truncate_partial_data_page(struct inode *inode, u64 from, page =get_lock_data_page (inode, index, true);if (IS_ERR (page)) -return 0 ; +return page; truncate_out:f2fs_wait_on_page_writeback (page,DATA , true);zero_user (page, offset,PAGE_SIZE - offset);
Signature · 6 lines
2.10.1 ------------------------------------------------------------------------------ Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Quoted 12 lines · Yunlei He
This patch fix a error return value in
truncate_partial_data_pageSigned-off-by Yunlei He <[email protected]>--- fs/f2fs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/f2fs/file.c +0
-0
fs/f2fs/file.c static int truncate_partial_data_page(struct inode *inode, u64 from, · line 532
Quoted 5 lines
fs/f2fs/file.c +1
-1@@ -529,7 +529,7 @@ static int truncate_partial_data_page(struct inode *inode, u64 from, page =get_lock_data_page (inode, index, true);if (IS_ERR (page)) -return 0 ; +return page;
return PTR_ERR(page);
Thanks,
fs/f2fs/file.c static int truncate_partial_data_page(struct inode *inode, u64 from, · line 535
Quoted 4 lines
fs/f2fs/file.c +0
-0truncate_out:f2fs_wait_on_page_writeback (page,DATA , true);zero_user (page, offset,PAGE_SIZE - offset);
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Jaegeuk Kim
maintainerQuoted 14 lines · Chao Yu
Quoted 13 lines · Yunlei He
This patch fix a error return value in
truncate_partial_data_pageSigned-off-by Yunlei He <[email protected]>--- fs/f2fs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/f2fs/file.c +0
-0@@ -529,7 +529,7 @@ static int truncate_partial_data_page(struct inode *inode, u64 from,
Quoted 6 lines
fs/f2fs/file.c static int truncate_partial_data_page(struct inode *inode, u64 from, · line 532
Quoted 4 lines
fs/f2fs/file.c +1
-1page =get_lock_data_page (inode, index, true);if (IS_ERR (page)) -return 0 ; +return page;return
PTR_ERR(page);
Do we need this?
return PTR_ERR(page) == -ENOENT ? 0 : PTR_ERR(page);
Thanks,
Quoted 7 lines
Thanks,
Quoted 4 lines
fs/f2fs/file.c +0
-0truncate_out:f2fs_wait_on_page_writeback (page,DATA , true);zero_user (page, offset,PAGE_SIZE - offset);
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Quoted 22 lines · Jaegeuk Kim
Quoted 14 lines · Chao Yu
Quoted 13 lines · Yunlei He
This patch fix a error return value in
truncate_partial_data_pageSigned-off-by Yunlei He <[email protected]>--- fs/f2fs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/f2fs/file.c +0
-0@@ -529,7 +529,7 @@ static int truncate_partial_data_page(struct inode *inode, u64 from,Quoted 6 lines
fs/f2fs/file.c static int truncate_partial_data_page(struct inode *inode, u64 from, · line 532
Quoted 4 lines
fs/f2fs/file.c +1
-1page =get_lock_data_page (inode, index, true);if (IS_ERR (page)) -return 0 ; +return page;return
PTR_ERR(page);
Quoted 3 lines
Do we need this?
return
PTR_ERR(page)==-ENOENT? 0 :PTR_ERR(page);
Oh, right, agreed. :)
Thanks,
Quoted 4 lines
Thanks,
Quoted 1 line
Quoted 9 lines
Quoted 6 lines
Thanks,
Quoted 4 lines
fs/f2fs/file.c +0
-0truncate_out:f2fs_wait_on_page_writeback (page,DATA , true);zero_user (page, offset,PAGE_SIZE - offset);.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot
Hi Jaegeuk,
Quoted 15 lines · Jaegeuk Kim
Quoted 14 lines · Chao Yu
Quoted 13 lines · Yunlei He
This patch fix a error return value in
truncate_partial_data_pageSigned-off-by Yunlei He <[email protected]>--- fs/f2fs/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)fs/f2fs/file.c +0
-0@@ -529,7 +529,7 @@ static int truncate_partial_data_page(struct inode *inode, u64 from,
Quoted 8 lines
Quoted 6 lines
fs/f2fs/file.c static int truncate_partial_data_page(struct inode *inode, u64 from, · line 532
Quoted 4 lines
fs/f2fs/file.c +1
-1page =get_lock_data_page (inode, index, true);if (IS_ERR (page)) -return 0 ; +return page;return
PTR_ERR(page);Do we need this?
Yes, you are right, we need this if file has holes.
Thanks.
Quoted 6 lines
return
PTR_ERR(page)==-ENOENT? 0 :PTR_ERR(page);Thanks,
Quoted 1 line
Quoted 9 lines
Quoted 6 lines
Thanks,
Quoted 4 lines
fs/f2fs/file.c +0
-0truncate_out:f2fs_wait_on_page_writeback (page,DATA , true);zero_user (page, offset,PAGE_SIZE - offset);.
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most engaging tech sites, SlashDot.org! http://sdm.link/slashdot