+static void tgt_clean_by_tag(struct obd_export *exp, __u64 xid, __u16 tag)
+{
+ struct tg_export_data *ted = &exp->exp_target_data;
+ struct lu_target *lut = class_exp2tgt(exp);
+ struct tg_reply_data *trd, *tmp;
+
+ if (tag == 0)
+ return;
+
+ list_for_each_entry_safe(trd, tmp, &ted->ted_reply_list, trd_list) {
+ if (trd->trd_tag != tag)
+ continue;
+
+ LASSERT(ergo(tgt_is_increasing_xid_client(exp),
+ trd->trd_reply.lrd_xid <= xid));
+
+ ted->ted_release_tag++;
+ tgt_release_reply_data(lut, ted, trd);
+ }
+}
+