Alfonso III (20 December 910), called the Great (), was the king of León, Galicia and Asturias from 866 until his death. He was the son and successor of Ordoño I. In later sources he is the earliest to be called "Emperor of Spain." He was also titled "Prince of all Galicia" (Princeps totius Galletiae). Life Alfonso's reign was notable for his comparative success in consolidating the kingdom during the weakness of the Umayyad princes of Córdoba. He fought against and gained numerous victories over the Muslims of al-Andalus. During the first year of his reign, he had to contend with a usurper, Count Fruela of Galicia. He was forced to flee to Castile, but after a few months Fruela was assassinated and Alfonso returned to Oviedo. He defeated a Basque rebellion in 867 and, much later, a Galician one as well. He conquered Porto and Coimbra in 868 and 878 respectively. In about 869, he formed an alliance with the Kingdom of Pamplona, and solidified this link by marrying Jimena, who is thought to have been daughter of king García Íñiguez, or less likely, a member of the Jiménez dynasty, and also married his sister Leodegundia to a prince of Pamplona. In the Reconquista The following year, 867, Alfonso had to attend to an uprising in the eastern part of the kingdom, in Alava, according to the Chronicle of Albeda. According to the Chronicle of Sampiro, the revolt was led by Count Eylo. Sampiro describes these events as follows: His father, Ordoño, had begun the resettlement of the border territories and Alfonso continued with it. His first successes were in Portuguese lands, where King Alfonso's troops succeeded in locating the southwestern frontier on the Mondego river. Count Vimara Perez in 868 conquered Porto and resettled the district. In 878, the army of King Alfonso III, with Count Hermenegildo Gutiérrez in command, faced the Muslim forces led by the emir of Cordoba, Mohammad I, who had started an attack against Porto. After defeating the emir's forces and expelling the Muslim inhabitants of Coimbra and Oporto, Gutiérrez' Christian troops occupied and repopulated other cities, such as Braga, Viseo and Lamego, with men taken from Galicia. Coimbra, Lamego and Viseo were conquered again in 987 by Almanzor and it was not until 1064 when they were finally reconquered by King Ferdinand I of León. Alfonso III had to face the offensive of