LVM2/lib/metadata thin_manip.c
CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: zkabelac at sourceware.org 2011-11-03 15:58:20
Modified files:
lib/metadata : thin_manip.c
Log message:
Thin keep pool device in the same state
Leave the optimalisation to be done differently and preserve availability state of the pool device.
lib/metadata/thin_manip.c +5 -4
@@ -307,10 +307,11 @@if (activate) {/* If the pool was not yet activated, do it */ -if (!lv_is_active (lv) && - !activate_lv_excl (lv->vg->cmd, lv)) { -log_error ("Failed to activate %s." , lv->name); -return 0 ; +if (!lv_is_active (lv)) { +if (!activate_lv_excl (lv->vg->cmd, lv)) + return_0; +if (!deactivate_lv (lv->vg->cmd, lv)) + return_0; }/* If already active, do suspend resume *