cmdlib: Remove acquired_locks attribute from LUs
authorMichael Hanselmann <hansmi@google.com>
Tue, 10 May 2011 09:41:14 +0000 (11:41 +0200)
committerMichael Hanselmann <hansmi@google.com>
Tue, 10 May 2011 11:03:01 +0000 (13:03 +0200)
commit0d5a0b96b943ba633f1403c247f2e9ff9a77396d
tree18072dfa0d0e352462f911d0954acb4b9b15816b
parent0db3d0b5a931273a95cdd7822f7a4b71d8708ec0
cmdlib: Remove acquired_locks attribute from LUs

The “acquired_locks” attribute in LUs is used to keep a list of acquired
locks at each lock level. This information is already known in the lock
manager, which also happens to be the authoritative source. Removing the
attribute and directly talking to the lock manager saves us from having
to maintain the duplicate information when releasing locks.

Signed-off-by: Michael Hanselmann <hansmi@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>
lib/cmdlib.py
lib/mcpu.py
test/mocks.py