U.S. Defense Secretary Ash Carter said Sunday that training and advising Afghan security forces is "becoming the heart" of a U.S. military mission that is winding down after 13 years of war.

Carter spoke to a gathering of about 100 soldiers, telling them that their work as advisers to the Afghan military is key to cementing security gains.

"We want it to be permanent and lasting," he said.

Kandahar is a regional hub for the U.S. training and advising mission.

Carter told the soldiers that they deserve credit for improving the competence and professionalism of the Afghan army and police.

He said the Afghan security forces are strong and now "stand a chance" of prevailing over the Taliban in a lasting way.

Carter got briefed on American military operations at Kandahar airfield in southern Afghanistan as part of what he called a listening tour of the war zone in his first week as defense secretary.

On his second day in Afghanistan, Carter flew to Kandahar from Kabul, the capital, where he had held a series of talks with Afghan government leaders and American military commanders.

Kandahar is home to the Afghan Army's 205th Corps, elements of which are involved in a major offensive against the Taliban in neighboring Helmand province. U.S. special operations forces also use the airfield at Kandahar to launch counterterrorism operations.

Under the Obama administration's exit plan for Afghanistan, the U.S. military presence at Kandahar will close down this year. President Barack Obama, however, is considering changes to the plan, including the possibility of keeping Kandahar open longer while keeping more U.S. troops in Afghanistan this year and next than presently planned.

An Obama decision may come as early as next month when he hosts Afghan President Ashraf Ghani at the White House.

The U.S. combat mission ended two months ago, and the focus this year for the 10,000 troops who remain is on consolidating gains in the development of the Afghan forces while also carrying out U.S. counterterrorism raids on remnants of Al Qaeda and associated extremist groups.

In a question-and-answer session with his audience of soldiers, Carter was asked on Sunday about concerns that the White House micromanages the Pentagon.

Carter said he considers it his duty to speak his mind to the president but also to follow his direction once a policy decision has been made.

"I won't pull any punches," Carter said. "I'm going to play it absolutely straight."

His predecessor, Chuck Hagel, was ousted in part for a perceived failure to provide strong policy options. Others who have run the Pentagon under Obama complained later of being micromanaged by the White House staff.