Merge "API for granting/revoking runtime permissions." into pi-dev