diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index 5b7a15db4953..480f1f616e7b 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -6403,6 +6403,8 @@ static int ext4_try_to_expand_extra_isize(struct inode *inode, struct ext4_iloc iloc, handle_t *handle) { + if (sb_rdonly(inode->i_sb)) + return 0; int no_expand; int error;