BALTIMORE -- A.J. Burnett admittedly wasn't at his best. He tried to get comfortable on the mound, and never came close.
Alex Rios had three hits and drove in the go-ahead run in a four-run fifth inning, leading the Blue Jays to a 6-4 victory Tuesday night.
Burnett (5-3) allowed four runs and six hits in 6 2/3 innings to win his third straight start. He struck out eight and walked two.
"I felt a little off. I started off and felt good, but I felt a little erratic," he said. "I didn't have my best stuff tonight, obviously, but I battled."
It was the first time in four career starts against Baltimore that Burnett allowed more than five hits. He pitched a three-hitter against the Orioles six days earlier and is 3-0 lifetime against Baltimore.
"He wasn't as sharp as he was, I think, in his last couple of times out," Toronto manager John Gibbons said. "He did what he needed to do: He got the win. That's the bottom line."
Jason Phillips homered for the Blue Jays, who have won five of seven, including four straight against the Orioles.
Last month, Baltimore swept a three-game series at home against Toronto.
"Wins on the road are important right now, especially against these guys," Burnett said. "They swept us last time, so it's good to come in here and get a W."
Brian Roberts homered for Baltimore, and Nick Markakis had three hits. The loss dropped the Orioles a season-high five games under .500 (20-25).
Toronto took a 6-2 lead in the fifth against Daniel Cabrera (3-5). After a single and two walks loaded the bases, Rios hit an RBI single and another run scored when Lyle Overbay bounced into a 4-6-3 double play. Vernon Wells followed with a run-scoring single and scored when Cabrera dropped a throw to first on a grounder by Matt Stairs.
Pitching for the first time since May 15, Cabrera lasted only 4 2/3 innings, his shortest outing of the season. He gave up seven hits, walked two and hit a batter.
"He could have been a little rusty early on, and then the inning he gave up four runs I think he kind of lost his composure a little bit," Orioles manager Sam Perlozzo said. "He just did a little damage control in that situation, we're OK."
Cabrera's demise in the fifth inning began with a leadoff walk to Aaron Hill, who came around to score the tiebreaking run.
"I don't think Daniel had his command tonight, and then when he walked somebody, instead of just bearing down and making some good pitches, he let it get to him and it just snowballed," Perlozzo said.
Roberts hit a two-run homer in the bottom half and Markakis followed with a double, but Burnett retired the next seven batters before being lifted.
Scott Downs and Casey Janssen followed, and Jeremy Accardo worked a perfect ninth for his fourth save. Accardo hasn't allowed an earned run in 20 innings.
Rios opened the game with a single and scored on a two-out double by Troy Glaus. Phillips hit a drive into Baltimore's bullpen leading off the third, his first home run since Aug. 11, 2005.
Burnett had five strikeouts through three shutout innings before running into trouble in the fourth. After a double and two walks loaded the bases with no outs, Aubrey Huff hit an RBI single and Baltimore pulled even when Melvin Mora hit into a double play.
"We just needed one fly ball or a base hit with the bases loaded, and we've got a different ballgame," Perlozzo said.
Baltimore CF Corey Patterson was omitted from the starting lineup because of an 0-for-17 skid that dropped his batting average to .219. ... Blue Jays DH Frank Thomas went 0-for-2 against Cabrera and is 0-for-10 against him lifetime. ... Seeking a homer in a fourth straight game, Stairs went 0-for-3 before being removed in the sixth. ... Janssen hasn't allowed an earned run in 13 straight appearances.