WASHINGTON (Reuters) - The U.S. military will fight Islamic State in Syria “as long as they want to fight,” Defense Secretary Jim Mattis said on Monday, describing a longer-term role for U.S. troops long after the insurgents lose all of the territory they control.

U.S. Secretary for Defense, Jim Mattis, sits opposite Britain's Secretary of State for Defence, Gavin Williamson, before a meeting at the Ministry of Defence (MoD) in central London, Britain November 10, 2017. REUTERS/Simon Dawson

As U.S.-backed and Russian-backed forces battle to retake the remaining pockets of Islamic State-held terrain, Mattis said the U.S. military’s longer-term objective would be to prevent the return of an “ISIS 2.0.”

“The enemy hasn’t declared that they’re done with the area yet, so we’ll keep fighting as long as they want to fight,” Mattis said, speaking to reporters at the Pentagon about the future of U.S. operations in Syria.

He also stressed the importance of longer-term peace efforts, suggesting U.S. forces aimed to help set the conditions of a diplomatic solution in Syria, now in its seventh year of civil war.

“We’re not just going to walk away right now before the Geneva process has traction,” he added.

U.S. President Donald Trump and Russian President Vladimir Putin affirmed joint efforts to stabilize Syria as its civil war wanes, including with the expansion of a July 7 truce in the southwestern triangle bordering Israel and Jordan.

Mattis said he believed the southwestern zone was working, and spoke hopefully about additional areas in the future that might allow for more refugees to return home.

“You keep broadening them. Try to (demilitarize) one area then (demilitarize) another and just keep it going, try to do the things that will allow people to return to their homes,” he told reporters at the Pentagon.

He declined to enter into specifics about any future zones.

Russia, which has a long-term military garrison in Syria, has said it wants foreign forces to quit the country eventually.

Turkey said on Monday the United States had 13 bases in Syria and Russia had five. The U.S-backed Syrian YPG Kurdish militia has said Washington has established seven military bases in areas of northern Syria.

The U.S.-led coalition says it does not discuss the location of its forces.

One key aim for Washington is to limit Iranian influence in Syria and Iraq, which expanded during the war with Islamic State.