Chicago White Sox pitcher Danny Farquhar is “progressing well” after undergoing emergency surgery to reduce swelling from a brain aneurysm, his team said on Monday.

The White Sox said Farquhar had use of his extremities, was able to respond to questions and commands, and could speak to doctors and family members.

His condition was «critical but neurologically stable,” the statement said.

Farquhar, 31, passed out in the dugout during Friday’s game between the White Sox and the Houston Astros.

He was treated at the scene by team doctors and ambulance personnel before being transported to Chicago’s Rush University Hospital.

“We are just very happy that he’s trending in the right direction,” White Sox manager Rick Renteria told ESPN on Monday.

“To know that he’s able to move and speak, to know that his family is there, he knows everybody cares for him.

“We are going in the right direction and very guardedly optimistic about the outcome.”

Farquhar is 10-15 with a 3.93 ERA in 253 career relief appearances with Toronto, Seattle, Tampa Bay and Chicago.