In osd_create, if the newly created inode had already contained
correct XATTR_NAME_LMA but failed to update the OI, it will clear
osd_object->oo_inode, the osd_object should also be dropped.
Signed-off-by: Hongchao Zhang <hongchao@whamcloud.com>
Change-Id: I4ff5952c154ce459c78514b88b1810471635c703
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/55571
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
result = __osd_oi_insert(env, obj, fid, th);
if (result && inode) {
+ set_bit(LU_OBJECT_HEARD_BANSHEE,
+ &obj->oo_dt.do_lu.lo_header->loh_flags);
+ obj->oo_dt.do_lu.lo_header->loh_attr &= ~LOHA_EXISTS;
+
spin_lock(&obj->oo_guard);
clear_nlink(inode);
spin_unlock(&obj->oo_guard);