U.S. president climbs down after remarks on allied troops in Afghan war provoked strong pushback from NATO allies.