reorder functions

Change-Id: I7137f89a61c7055adfe45b343fe1614998727715