The Tatar tribes arriving in the 14th century settled in the lands of the Grand Duchy of Lithuania. Skilled warriors and great mercenaries, their settlement was promoted by the Grand Dukes of Lithuania, among them Gediminas, Algirdas and Kęstutis. The Tatars who settled in Lithuania, Ruthenia and modern-day eastern Poland were allowed to preserve their Sunni religion in exchange for military service. The initial settlements were mostly temporary and most of the Tatars returned to their native lands after their service expired. However, in the late 14th century Grand Duke Vytautas (named by the Tatars "Wattad", that is "defender of Muslims") and his brother King Władysław Jagiełło started to settle Tatars in the Polish–Lithuanian–Teutonic borderlands. The Lipka Tatars, as they are known, migrated from the lands of the Golden Horde and in large part served in the Polish–Lithuanian military. The largest of such groups to arrive to the area was a tribe of Tokhtamysh, who in 1397 rebelled against his former protector Tamerlane and sought asylum in the Grand Duchy. The Tatars under his command were all granted szlachta (nobility) status, a tradition that was preserved until the end of the Commonwealth in the 18th century. Light Tatar cavalry, used both as skirmishers and reconnaissance troops took part in many of the battles against the foreign armies in the 15th century and afterwards, including the battle of Grunwald in which the Tatars fought commanded by their leader, Jalal ad-Din khan.