diff --git a/WHATS_NEW b/WHATS_NEW index e68735b57..83725073a 100644 --- a/WHATS_NEW +++ b/WHATS_NEW @@ -1,12 +1,13 @@ Version 2.02.49 - ================================ + Exclude VG_GLOBAL from vg_write_lock_held so scans open devs read-only again. Add unit test case for liblvm VG create/delete APIs. Add liblvm APIs to implement creation and deletion of VGs. - Initialize cmd->cmd_line to "liblvm". - Place handles to liblvm objects for pv, vg, lv, lvseg, pvseg inside lvm.h + Initialize cmd->cmd_line to "liblvm" in new liblvm library. + Place handles to liblvm objects for pv, vg, lv, lvseg, pvseg inside lvm.h. Refactor vgsplit and vgextend to remove READ_REQUIRE_RESIZEABLE flag. - Changed exit() to _exit() after fork(); avoid flushing libc buffers twice. - Fixed invalid type being passed as printf argument on Sparc64. + Changed exit() to _exit() after fork() to avoid flushing libc buffers twice. + Add cast to log_info arg in _find_labeller to avoid Sparc64 warning. Make cmd->cmd_line const. Fix dev name mismatch in vgcreate man page example. Refactor vg_remove_single for use in liblvm. diff --git a/lib/locking/locking.c b/lib/locking/locking.c index 5c04b4f07..032f8ba13 100644 --- a/lib/locking/locking.c +++ b/lib/locking/locking.c @@ -189,10 +189,12 @@ void reset_locking(void) _unblock_signals(); } -static void _update_vg_lock_count(uint32_t flags) +static void _update_vg_lock_count(const char *resource, uint32_t flags) { + /* Ignore locks not associated with updating VG metadata */ if ((flags & LCK_SCOPE_MASK) != LCK_VG || - (flags & LCK_CACHE)) + (flags & LCK_CACHE) || + !strcmp(resource, VG_GLOBAL)) return; if ((flags & LCK_TYPE_MASK) == LCK_UNLOCK) @@ -356,7 +358,7 @@ static int _lock_vol(struct cmd_context *cmd, const char *resource, uint32_t fla == LCK_READ); } - _update_vg_lock_count(flags); + _update_vg_lock_count(resource, flags); } _unlock_memory(flags);