MILWAUKEE -- As he was about to be intentionally walked, Brewers infielder Mark Reynolds was chuckling in the batter's box, knowing that his team needed a starting pitcher, Yovani Gallardo, to get a big hit to beat the Baltimore Orioles.
It turns out that Gallardo got the last laugh.
With the Brewers out of position players, Gallardo's pinch-hit double off T.J. McFarland scored Reynolds from first with two outs in the 10th inning to lift the Brewers to a 7-6 victory over the Orioles at Miller Park.
"I kind of made eye contact with Yo and said, 'Let's go, man,'" Reynolds said. "He's a good hitter. He threw a fastball and Yo put a good swing on it and it was fun."
McFarland (0-1) retired the first two batters of the 10th before intentionally walking Reynolds, knowing the Brewers were out of position players and Francisco Rodriguez was due up next. In 757 games, Rodriguez (2-1) has only two plate appearances, so manager Ron Roenicke looked to Gallardo, who has a .202 lifetime average and 12 homers.
"You're hoping to get something lucky, but I think Yo has shown over the years that he's really a good hitter," Roenicke said.
Gallardo belted a 2-0 pitch off the center-field wall to easily score Reynolds without a play at the plate.
It was the first time that a pitcher had a pinch-hit, walk-off hit since Glendon Rusch did it for the Brewers in the 14th inning against the Houston Astros on April 19, 2003, according to the Elias Sports Bureau.
The unique nature of the win wasn't lost on the Brewers.
"You can't write a script like that," Reynolds said. "It's pretty cool."
The Brewers dumped a bucket of ice water on Gallardo, who is scheduled to start the series finale on Wednesday, as he conducted a television interview on the field immediately after the game.
"I wanted to put the ball in play and see what happens," Gallardo said. "I think the pitch wasn't where he wanted it, I'm pretty sure. I made good contact."
Baltimore manager Buck Showalter said he hoped Gallardo had left the ballpark early to prepare for Wednesday's start.
"I was hoping he had gone home," Showalter said.
No such luck for the Orioles. Instead, Gallardo had gone to the batting cages with infielder Irving Falu and Ryan Braun to take a few swings.
"Anytime for anybody, to come in and pinch-hit and get a base hit to get a win, most importantly, is very exciting," Gallardo said. "It was a weird game today but we came out on top. That's the main thing."
McFarland said he pitched Gallardo like he would to any other batter.
"He obviously was ambushing a fastball there and unfortunately I left it up and he hit it," McFarland said. "But I don't think I would pitch a pitcher any differently than any other hitter. The pitch I threw was not a good pitch to any hitter. I got behind him 2-0 and threw a fastball he could hit."
Milwaukee had tied it at 6 in the ninth, when Jonathan Lucroy beat out an infield hit and avoided a tag at first on a slow roller to third, allowing pinch-runner Elian Herrera to score from third with two outs.
The Brewers had opened an early 5-0 lead on a three-run home run by Carlos Gomez and solo homers from Reynolds and Khris Davis.
But the Orioles scored three unearned runs off Milwaukee starter Matt Garza in the seventh to take a 6-5 lead. Brewers shortstop Jean Segura made a costly throwing error on what could have been an inning-ending double play. Two batters later, pinch-hitter Steve Pearce hit a three-run home run to give Baltimore a 6-5 lead.
Garza pitched 6 2/3 innings, giving up six runs, three earned, on five hits and two walks while striking out nine.
"I felt like I had the best stuff I've had so far," Garza said. "My command was there, my mechanics -- everything. It was just one of those days where everything was working well until that one pitch [to Pearce].
"You just hang your head and get ready for the next start. You don't change too much and stick with what I did today. I felt like I threw the ball well until late."
Baltimore starter Wei-Yin Chen pitched five innings, giving up five runs on seven hits while striking out six. He had only given up four homers in his first nine starts before yielding three to the Brewers.
Joe DiGiovanni is a contributor to MLB.com. This story was not subject to the approval of Major League Baseball or its clubs.