In the late 11th century, Magnus Barefoot, the Norwegian king, launched a military campaign which in 1098 led the king of Scotland to quitclaim to Magnus all claim of sovereign authority over the territory of the Kingdom of the Isles. However, a coup some 60 years later, led by a Norse-Gael named Somerled, detached the whole of the Suðreyjar from Norway and transformed it into an independent kingdom. After Somerled's death in 1164, nominal Norwegian authority was established, but practical control of the realm was divided between Somerled's sons and the heirs of Somerled's brother-in-law, the Crovan Dynasty. His son Dougall received the former territory of the Cenél Loairn, now known as Lorn, of which Mull formed part.