BOSTON -- Michael Pineda has been told he needs Tommy John surgery on his right elbow, but the pitcher is going for a second opinion before making a final decision, New York Yankees general manager Brian Cashman announced Friday.

The timing of the flexor muscle strain and partial tear in the UCL ligament could not have been worse for Pineda. He is scheduled to become a free agent for the first time in his career this offseason.

Pineda, 28, had fought back from a serious shoulder injury, suffered in 2012 during his first spring with the Yankees. It took him two years to come back. This season, he is 8-4 with a 4.39 ERA, but he has struggled.

Yankees starter Michael Pineda is seeking a second opinion on his UCL tear diagnosis in hopes of avoiding Tommy John surgery, which the team has recommended. Photo/Charlie Riedel

In addition, first baseman Greg Bird, who has missed most of the season with a bruised bone in his ankle, may need surgery for a condition called os trigonum, which is excess bone growth in his foot.

The ankle injury may be causing inflammation in his foot that Cashman said could likely lead to surgery, though Bird still needs to see another doctor before the team, Bird and his agents discuss options.

If Bird has surgery, he would be out at least another two months. He missed all of last year after shoulder surgery.

The Yankees made a trade with the Milwaukee Brewers to acquire minor league slugger Garrett Cooper on Thursday. He is expected to make his major league debut at first base against the Boston Red Sox at Fenway Park on Friday.

Cashman said second baseman Starlin Castro (hamstring) could return Saturday.

Pineda's injury adds to the disarray in the Yankees' rotation. Masahiro Tanaka, who is supposed to be the team's ace, will not start until the fourth game of the second half, Sunday night against the Red Sox.

The Yankees started rookie Jordan Montgomery on Friday night, followed by All-Star Luis Severino on Saturday. Bryan Mitchell will start the day game of the doubleheader Sunday.

In Minnesota, CC Sabathia and Luis Cessa will make starts on Monday and Tuesday. Cashman said top prospect Chance Adams could be a starting option at some point.

Cashman said the injury to Pineda will not change his approach to the trade deadline.

"We will be careful buyers," Cashman said.