fix the unused macro, remove inline functions

simplification is good