grab_cache_page_write_begin() returns NULL on error, it doesn't return error pointers. Fixes: e18c65b2ac91 ('f2fs: key functions to handle inline data') Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx> diff --git a/fs/f2fs/inline.c b/fs/f2fs/inline.c index 69a923e38f0c..e0d800a1d79f 100644 --- a/fs/f2fs/inline.c +++ b/fs/f2fs/inline.c @@ -131,8 +131,8 @@ int f2fs_convert_inline_data(struct inode *inode, pgoff_t to_size) return 0; page = grab_cache_page_write_begin(inode->i_mapping, 0, AOP_FLAG_NOFS); - if (IS_ERR(page)) - return PTR_ERR(page); + if (!page) + return -ENOMEM; err = __f2fs_convert_inline_data(inode, page); f2fs_put_page(page, 1); -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html