More consolidation of lock handling