China exhibited much interest in foreign affairs, during the Tang and Song dynasties. From the 7th through the 10th Tang China was focused on securing the Silk Road as the selling of its goods westwards was central to the nation's economy. For a time China, successfully secured its frontiers by integrating their nomadic neighbors such as the Gokturks into their civilization. The Tang dynasty expanded into Central Asia and received tribute from Eastern Iran. Western expansion ended with wars with the Umayyad Caliphate and the deadly An Lushan Rebellion which resulted in an deadly but uncertain death toll of millions.