Armenia and Arran , and the Rawadid (955–1221) in Tabriz and Maragheh . In the east were the Hasanwayhids (959–1015) and the Annazid (990–1117) in Kermanshah , Dinawar and Khanaqin . In the west were the Marwanid (990–1096) of Diyarbakır . After these, the Ayyubid (1171–1250) of Syria and the Ardalan