Chemical and mechanical stabilization of martensite