Sync functions-common from devstack

This is a sync of shared functions-common from devstack.

Change-Id: If2683698ea432addd42b9f97ad5ce03de4774f0f
Merge "Sync functions-common from devstack"