--- /dev/null
+Index: linux-3.10.0-957.27.2.el7/fs/ext4/ext4.h
+===================================================================
+--- linux-3.10.0-957.27.2.el7.orig/fs/ext4/ext4.h
++++ linux-3.10.0-957.27.2.el7/fs/ext4/ext4.h
+@@ -1539,6 +1539,7 @@ enum {
+ EXT4_STATE_NO_EXPAND, /* No space for expansion */
+ EXT4_STATE_DA_ALLOC_CLOSE, /* Alloc DA blks on close */
+ EXT4_STATE_EXT_MIGRATE, /* Inode is migrating */
++ EXT4_STATE_IAM, /* Lustre IAM objects */
+ EXT4_STATE_DIO_UNWRITTEN, /* need convert on dio done*/
+ EXT4_STATE_NEWENTRY, /* File just added to dir */
+ EXT4_STATE_DIOREAD_LOCK, /* Disable support for dio read
+Index: linux-3.10.0-957.27.2.el7/fs/ext4/namei.c
+===================================================================
+--- linux-3.10.0-957.27.2.el7.orig/fs/ext4/namei.c
++++ linux-3.10.0-957.27.2.el7/fs/ext4/namei.c
+@@ -58,8 +58,10 @@ struct buffer_head *ext4_append(handle_t
+
+ if (unlikely(EXT4_SB(inode->i_sb)->s_max_dir_size_kb &&
+ ((inode->i_size >> 10) >=
+- EXT4_SB(inode->i_sb)->s_max_dir_size_kb)))
+- return ERR_PTR(-ENOSPC);
++ EXT4_SB(inode->i_sb)->s_max_dir_size_kb))) {
++ if (!ext4_test_inode_state(inode, EXT4_STATE_IAM))
++ return ERR_PTR(-ENOSPC);
++ }
+
+ /* with parallel dir operations all appends
+ * have to be serialized -bzzz */
rhel7.6/ext4-limit-number-of-scanned-extents-in-status-tree-.patch
rhel7.6/ext4-cleanup-flag-definitions-for-extent-status-tree.patch
rhel7.6/ext4-introduce-aging-to-extent-status-tree.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-limit-number-of-scanned-extents-in-status-tree-.patch
rhel7.6/ext4-cleanup-flag-definitions-for-extent-status-tree.patch
rhel7.6/ext4-introduce-aging-to-extent-status-tree.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-limit-number-of-scanned-extents-in-status-tree-.patch
rhel7.6/ext4-cleanup-flag-definitions-for-extent-status-tree.patch
rhel7.6/ext4-introduce-aging-to-extent-status-tree.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-optimize-ext4_find_delalloc_range-in-nodelalloc.patch
rhel7.6/ext4-export-orphan-add.patch
suse15/ext4-export-mb-stream-allocator-variables.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-optimize-ext4_find_delalloc_range-in-nodelalloc.patch
rhel7.6/ext4-export-orphan-add.patch
suse15/ext4-export-mb-stream-allocator-variables.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-optimize-ext4_find_delalloc_range-in-nodelalloc.patch
rhel7.6/ext4-export-orphan-add.patch
suse15/ext4-export-mb-stream-allocator-variables.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-optimize-ext4_find_delalloc_range-in-nodelalloc.patch
rhel7.6/ext4-export-orphan-add.patch
suse15/ext4-export-mb-stream-allocator-variables.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-export-orphan-add.patch
rhel7.6/ext4-mmp-dont-mark-bh-dirty.patch
ubuntu18/ext4-include-terminating-u32-in-size-of-xattr-entries-when-expanding-inodes.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel7.6/ext4-mmp-dont-mark-bh-dirty.patch
ubuntu18/ext4-include-terminating-u32-in-size-of-xattr-entries-when-expanding-inodes.patch
suse15/ext4-export-mb-stream-allocator-variables.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel8/ext4-mballoc-skip-uninit-groups-cr0.patch
rhel8.1/ext4-mballoc-prefetch.patch
rhel8/ext4-xattr-disable-credits-check.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel8/ext4-mballoc-skip-uninit-groups-cr0.patch
rhel8.1/ext4-mballoc-prefetch.patch
rhel8/ext4-xattr-disable-credits-check.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel8/ext4-mballoc-skip-uninit-groups-cr0.patch
rhel8/ext4-mballoc-prefetch.patch
rhel8/ext4-xattr-disable-credits-check.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
rhel8/ext4-export-mb-stream-allocator-variables.patch
ubuntu19/ext4-iget-with-flags.patch
rhel8/ext4-simple-blockalloc.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
linux-5.4/export-ext4fs-dirhash-helper.patch
linux-5.4/ext4-misc.patch
rhel8/ext4-simple-blockalloc.patch
+base/ext4-no-max-dir-size-limit-for-iam-objects.patch
inode = osd_oi_index_open(info, osd, name, &oi_feat, create);
if (IS_ERR(inode))
RETURN(PTR_ERR(inode));
+ ldiskfs_set_inode_state(inode, LDISKFS_STATE_IAM);
if (!osd->od_dt_dev.dd_rdonly) {
/* 'What the @fid is' is not imporatant, because these objects