Merge changes from topic "jun2" into rvc-dev

* changes:
  Flip ENABLE_DYNAMIC_PERMISSIONS, attempt #5.
  More AMS/UGMS lock detangling.