Wednesday found the governments of Turkey and Iraq summoning each others’ ambassadors for acrimonious exchanges over Turkish troops stationed near Mosul, as the battle to liberate that city from ISIS approaches.

“Ankara believes an offensive by Shia militias will backlash in Sunni-populated Mosul and argues that Sunni fighters, trained by Turkish troops in the Bashiqa military camp, should be a key part of the Mosul offensive,” Hurriyet Daily News explains.

The Turkish Foreign Ministry summoned Iraq’s ambassador to complain about the Iraqi parliament’s demand for Turkish troops to pull out of Iraq. The Iraqi Foreign Ministry summoned Turkey’s ambassador to complain about Turkey’s “provocative” comments about keeping those troops in Iraq.

The Turks say their troops were invited by Massoud Barzani, president of the Kurdish autonomous region in Iraq, to help train Kurdish forces for the liberation of Mosul. The Iraqi Foreign Ministry denounced the Turkish troops’ “hostile occupying forces” in their message to the Turkish ambassador.

The Turkish Foreign Ministry proceeded to condemn Baghdad’s condemnation, calling it an “unacceptable decision” that included “dirty accusations against the Turkish president.”

“Turkey has lost thousands of citizens due to the terror threat from Iraq and has defended Iraq’s territorial integrity, sovereignty, stability and security taking huge political and economic risks, despite being affected directly by the instability caused by the sectarian approach of Iraq,” the Turkish statement insisted. “Turkey will maintain its determination in fighting against terrorist organizations that threaten national security as a right to self-defense, as well as in protecting the territorial integrity and sovereignty of Iraq, with which it shares a common future.”

On Wednesday, Reuters reported Iraqi Prime Minister Haider al-Abadi ratcheted up the already tense situation in a televised interview.

“We have asked the Turkish side more than once not to intervene in Iraqi matters and I fear the Turkish adventure could turn into a regional war,” Abadi warned. “The Turkish leadership’s behavior is not acceptable and we don’t want to get into a military confrontation with Turkey.”

In addition to Ankara’s concerns about Shiite militias participating in the battle for Mosul, Reuters notes it is concerned about the Turkmen population living in the region and is also “uncomfortable with the arrangement of Kurdish forces expected to take part in the offensive.”

The Kurdish Rudaw news service reports Shiite militia leaders in Iraq aren’t exactly helping to calm the situation down. One militia leader agreed with Baghdad that Turkish forces in northern Iraq are “occupiers,” and threatened to attack Turkish troops “if they do not retreat from Iraqi land.”

“If they insist on staying in Iraq we will treat them as enemies. We fight them the way we fight ISIS,” militia spokesman Yousif al-Kilabi declared.

Rudaw notes that the Turkish parliament voted on Saturday to extend their army’s military mandates in both Iraq and Syria, which does give the Iraqis some reason to suspect more Turkish forces could soon be crossing into northern Iraq.

It’s unclear exactly how many Turkish troops are currently in Iraq. The UK Telegraph estimates about 2,000 of them were dispatched to fight the Islamic State last year, while Rudaw reports additional forces were sent to protect the Turkish base in Bashiqa, near Mosul, from ISIS attacks in December.