BALTIMORE -- The Baltimore Orioles control their own destiny for a spot in the playoffs.
After earning a series split with a 2-1 victory over the Tampa Bay Rays on Sunday, the Orioles can also set their sights on an American League East crown. Mark Trumbo hit a go-ahead home run the eighth inning to provide the victory in the series finale against Tampa Bay.
"This time of year, someone's got to step up at some point in the game," said Trumbo, who leads the major league with 43 homers. "We did a real nice job. It was a well-played game, but we just needed to get that hit there at the end. So it was nice."
Baltimore won four of its past six games and holds one of the wild-card spots for the playoffs entering the final two weeks of the season. The Orioles open a pivotal four-game series with the first-place Boston Red Sox on Monday.
"I know our guys are going to be ready and I know Boston is going to be ready," Orioles manager Buck Showalter said. "They're in a good spot. We knew coming out of spring training after watching all the things they did in the offseason they were going to be one of the favorites going in."
With the game tied 1-1, Trumbo hit the first pitch off Ryan Garton (1-1) 433 feet over the center-field fence. Zach Britton allowed a leadoff single to Steven Souza in the ninth, but he struck out pinch hitter Logan Forsythe and got Alexei Ramirez to ground out for his 45th save, best in the American League.
"Hitters like that, they don't miss, so it's on me," Garton said. "I just have to be better."
Manny Machado got his career-high 36th home run of the season for the Orioles. Reliever Brad Brach (10-3) picked up the win with a scoreless eighth.
Baltimore left-hander Wade Miley was having one of his best outings for the team before he had to leave after warming up in the fifth inning with "upper back cramps." He allowed one hit over four scoreless innings.
Miley entered the game 1-5 with an 8.41 ERA in eight starts for Baltimore since being acquired from Seattle at the non-waiver trade deadline.
Corey Dickerson got his 21st home run for the Rays. Baltimore finished the season series against Tampa Bay 13-6.
Miley retired nine consecutive batters before allowing a leadoff single to Mikie Mahtook in the fourth. Miley then hit Kevin Kiermaier before striking out Evan Longoria and Orioles catcher Caleb Joseph threw out Mahtook trying to steal third.
When Miley left with the injury, Darren O'Day, who came off the disabled list earlier in the day, entered in the fifth and allowed a homer to Dickerson on his first pitch that gave the Rays a 1-0 lead. It was the first time in club history the Rays homered in every game of a road trip that consisted of 10 or more games.
"We are giving teams a good game all the way to the end," Tampa Bay manager Kevin Cash said. "We've won some of them and we've lost some of them."
Machado tied the game with a lead-off homer off Rays starter Jake Odorizzi in the sixth. Odorizzi allowed just one run on five hits with three strikeouts over six innings.
"We played a great series here," Odorizzi said. "We could have easily swept the series, but we got the split. That's just how it goes. We played a tough series."
NOTES: Orioles 1B/OF Trey Mancini, who was the team's minor league Player of the Year in 2015, had his contract purchased from Triple-A Norfolk. To make room, OF Steve Pearce (strained flexor mass) was placed on the 60-day DL. ... Rays C Bobby Wilson missed the series finale because of a death on his wife's side of the family. Wilson is batting .240 with six homers and 32 RBIs in 69 games. ... Orioles OF Joe Rickard (thumb) has not shown enough improvement with his injury to rejoin the team this season. He could opt to have surgery, according to Showalter.