Muslim clerics from Gansu studied in Mecca and Yemen under Naqshbandi Sufi teachers. Two different forms of Sufism were brought back to northwest China by two charismatic Hui sheikhs: Khufiyya, associated with Ma Laichi (1681–1766), and the more radical Jahriyya, founded by Ma Mingxin (1719?–1781). These coexisted with the more traditional, non-Sufi Sunni practices, centered around local mosques and known as gedimu (qadim, or ). The Khufiyya school and non-Sufi gedimu tradition—both tolerated by Qing authorities—were referred to as "Old Teaching" (), while Jahriyya, viewed by authorities as suspect, became known as the "New Teaching" (). Disagreements between adherents of Khufiyya and Jahriya, as well as perceived mismanagement, corruption and the anti-Sufi attitudes of Qing officials, resulted in uprisings by Hui and Salar followers of the New Teaching in 1781 and 1783, but these were promptly suppressed. Hostilities between different groups of Sufis contributed to the violent atmosphere before the Dungan revolt between 1862 and 1877. In the Jahriyya revolt sectarian violence between two suborders of the Naqshbandi Sufis, the Jahriyya Sufi Muslims and their rivals, the Khafiyya Sufi Muslims, led to a Jahriyya Sufi Muslim revolt which the Qing dynasty in China crushed with the help of the Khafiyya Sufi Muslims. Course of the revolt As Taiping troops approached southeastern Shaanxi in the spring of 1862, the local Han Chinese, encouraged by the Qing government, formed Yong Ying militias to defend the region against the attackers. Afraid of the now-armed Han, the Muslims formed their own militia units as a response. According to some historians, the Dungan revolt began in 1862, not as a planned uprising but as a succession of local brawls and riots triggered by trivial causes. There were also rumors—false, as it turned out—spread that the Hui Muslims were aiding the Taiping Rebels. It was also said that the Hui Ma Hsiao-shih claimed that the Shaanxi Muslim revolt was connected to the Taiping. Many Green Standard Army troops of the Imperial army were Hui. According to some historians, one of the incidents which led to the revolt was caused by a fight over the price of bamboo poles that a Han merchant was selling to a Hui. After this fight, Hui mobs attacked the Han and other Hui people who had not joined them in revolt. It was this seemingly trivial and unimportant dispute over bamboo poles that set off the full-scale revolt. However, according to