Austria says it is planning to phase out special measures that have allowed thousands of migrants to travel freely from Hungary to Western Europe.