On the conditional total stability of equilibrium for mechanical systems