Merge "Tidy up module-lib API and locks" am: 98ab83c37d am: 779b5c6ee0 am: 1fc568f878

Change-Id: I4c7039b54aa185447108622b0608689ddf45bc2f