Kent, and established a second West Saxon bishopric at Sherborne, covering the area west of Selwood Forest, which formed an important boundary between east and west Wessex. Near the end of his life he followed in Cædwalla's footsteps by abdicating and making a pilgrimage to Rome. The throne then passed to a series of other kings who claimed descent from Cerdic but whose supposed genealogies and relationship to one another are unknown. During the 8th century Wessex was overshadowed by Mercia, whose power was then at its height, and the West Saxon kings may at times have acknowledged Mercian overlordship. They were, however, able to avoid the more substantial control which Mercia exerted over smaller kingdoms. During this period Wessex continued its gradual advance to the west, overwhelming the British kingdom of Dumnonia (Devon). At this time Wessex took de facto control over much of Devon, although Britons retained a degree of independence in Devon until at least the 10th century. (William of Malmesbury claimed that the Britons and Saxons inhabited Exeter "as equals" until 927.) As a result of the Mercian conquest of the northern portion of its early territories in Gloucestershire and Oxfordshire, the Thames and the Avon now probably formed the northern boundary of Wessex, while its heartland lay in Hampshire, Wiltshire, Berkshire, Dorset and Somerset. The system of shires which was later to form the basis of local administration throughout England (and eventually, Ireland, Wales and Scotland as well) originated in Wessex, and had been established by the mid-8th century. Hegemony of Wessex and the Viking raids In 802 the fortunes of Wessex were transformed by the accession of Egbert who came from a cadet branch of the ruling dynasty that claimed descent from Ine's brother Ingild. With his accession the throne became firmly established in the hands of a single lineage. Early in his reign he conducted two campaigns against the "West Welsh", first in 813 and then again at Gafulford in 825. During the course of these campaigns he conquered the western Britons still in Devon and reduced those beyond the River Tamar, now Cornwall, to the status of a vassal. In 825 or 826 he overturned the political order of England by decisively defeating King Beornwulf of Mercia at Ellendun and seizing control of Surrey, Sussex, Kent and Essex from the Mercians, while with his help East Anglia broke away from Mercian control.