rc = lod_sub_prep_llog(env, lod,
sub_tgt->ltd_tgt,
sub_tgt->ltd_index);
- if (rc == 0)
- sub_tgt->ltd_active = 1;
+ sub_tgt->ltd_active = !rc;
} else {
lod_sub_fini_llog(env, sub_tgt->ltd_tgt,
NULL);
lod_getref(&lod->lod_ost_descs);
lod_foreach_ost(lod, tgt) {
- if (!tgt->ltd_active)
+ if (tgt->ltd_discon)
continue;
rc = dt_sync(env, tgt->ltd_tgt);
if (rc) {
lod_getref(&lod->lod_mdt_descs);
lod_foreach_mdt(lod, tgt) {
- if (!tgt->ltd_active)
+ if (tgt->ltd_discon)
continue;
rc = dt_sync(env, tgt->ltd_tgt);
if (rc) {
d = lu2lod_dev(obd->obd_lu_dev);
lod_getref(&d->lod_ost_descs);
lod_foreach_ost(d, tgt) {
- if (!tgt->ltd_active)
+ if (tgt->ltd_discon)
continue;
rc2 = obd_set_info_async(env, tgt->ltd_exp, keylen, key,
lod_getref(&d->lod_mdt_descs);
lod_foreach_mdt(d, tgt) {
- if (!tgt->ltd_active)
+ if (tgt->ltd_discon)
continue;
+
rc2 = obd_set_info_async(env, tgt->ltd_exp, keylen, key,
vallen, val, set);
if (rc2 != 0 && rc == 0)