BAGHDAD (Reuters) - Iraq’s parliament approved a law on Saturday that will transform Popular Mobilisation forces, a mostly Iranian-backed coalition of Shi’ite militias that played a role in fighting Islamic State, into a legal and separate military corps.

Disagreements over the paramilitary units are complicating efforts to pull Iraq together as forces battle to defeat Islamic State, the ultra-hardline Sunni group that overran a third of the country in 2014, proclaiming a “caliphate” that spans parts of Syria.

All the Shi’ite blocks in parliament voted for the bill in a session boycotted by lawmakers from the Sunni minority who object to the existence of armed forces outside the army and police.

Popular Mobilisation, or Hashid Shaabi in Arabic, was accused of abuses against Sunni civilians in towns and villages retaken from Islamic State, according to international human rights groups and the U.N. Human Rights Commissioner.

“I don’t understand why we need to have an alternative force to the army and the police,” said Sunni member of parliament (MP) Raad al-Dahlaki. “As it stands now, it would constitute something that looks like Iran’s Revolutionary Guard,” he added.

Iraqi forces started an offensive on Oct. 17 to capture Mosul, Islamic State’s last major city stronghold in Iraq, with air and ground support from a U.S.-led coalition. Kurdish and Popular Mobilisation forces are supporting the offensive.

The law does not say how many fighters will be incorporated under the legalized Popular Mobilisation corps, which currently claims to have more than 110,000 fighters, or define the breakdown between members from the different communities.

The government says between 25,000 and 30,000 members of the Hashid are Sunni tribal fighters and nearly all the rest are Shi’ites, with a few Yazidi and Christian units.

The Kurds have their own military force, called Peshmerga, deployed in the Kurdish autonomous area in northern Iraq.

The law provides for Popular Mobilisation to report directly to the prime minister, who is a Shi’ite under Iraq’s governing system that split top state positions between the different communities after the 2003 fall of Saddam Hussein.

The army reports to the defense minister, who is traditionally a Sunni, although the position has been vacant since the sacking by parliament of Khaled al-Obeidi in August.