Rename function to avoid conflict and remove dead code used by upei