LSU third baseman Josh Smith waits for the throw as Florida’s Nick Horvath slides into the base Sunday, March 26, 2017, in Gainesville, Fla.

GAINESVILLE, Fla. — Before his two-run, go-ahead home run cleared the wall in left-center field by a healthy margin, Cole Freeman was yelling and thumping his chest as he looked back at the LSU dugout.

It was that kind of eighth inning for LSU. Its 174-pound second baseman, proud owner of one career home run, was celebrating a no-doubter. It was the last of a trio of two-run homers that dramatically changed the tone of an important series against Florida and powered LSU to a 10-6 win in the series finale.

“I saw the left-fielder pulling up, and I was like, ‘Holy smokes that’s out,’” Freeman said. “As soon as I touched first base and realized it was out, that was about as pumped up as I’ve been.

“Who would’ve thought? Eight runs in the last two innings. Three home runs — and a home run from me. I was the last person anyone on the team was thinking, ‘OK, we need a home run from him.’ ”

It was a crazy scene, especially considering the previous 25 innings.

For the better part of seven innings Sunday, LSU (18-7, 4-2 Southeastern Conference) looked like the moribund group that had managed one run while dropping the first two games of its series against Florida (16-9, 2-4).

“Everything that could go wrong went wrong for two games and seven innings,” said LSU coach Paul Mainieri. “Then finally we start putting something together.”

The Tigers were looking at the very likely possibility of a sweep. They trailed 6-2 as they came to bat in the eighth and the four-run deficit seemed improbable to erase for a team that had three extra base hits all weekend.

Then, all of a sudden, the switch was flipped and LSU turned Ruthian, and it started with the Tigers best power hitter hitting a single.

Before the eighth inning, the top four hitters in LSU’s lineup — all of whom were hitting better than .363 entering the weekend — had gone a combined 5-41 in the Florida series. Though they had hit the ball hard in many cases, they were not finding holes in the Florida defense.

Then Greg Deichmann led off the eighth inning with a sharp single, ending a string of nine straight at-bats without a hit.

Two batters later, Josh Smith pounced on a fat slider that Florida right-hander Michael Byrne tried sneaking by on the first pitch of the at-bat. He yanked it down the right field line for a long home run.

“I got a good piece of it,” Smith said with a smile.

That prompted the first of three Florida pitching changes in the eighth inning. Beau Jordan brough about the next change.

The second pitch by right-hander Frank Rubio hit LSU’s Jake Slaughter. Maybe that was on his mind when he tried to go inside on Jordan, but didn’t go inside enough.

Jordan turned on the fastball on the inner part of the plate and sent it well over the fence in left field, into the trees beyond the bleachers, to tie the game. The LSU dugout erupted and enthusiastically greeted Jordan after he touched home plate.

“It felt really good to get things going in the dugout, because we’ve been kind of dead this weekend,” Jordan said. “It kind of riled us up a little bit.”

It was Jordan’s second big hit of the game. He ended LSU’s 0-17 streak with runners in scoring position against Florida pitching in the sixth inning, when he hit a bases- loaded single to left field. He finished with four RBIs.

“When Beau finally got that two-run single, it just kind of lifted us,” Mainieri said. “It loosened our kids up.”

Jordan’s homer chased Rubio from the game. Florida brought in left-hander Andrew Baker (1-2), and he promptly plunked Michael Papierski. Florida decided that was enough of him and brought in its fourth pitcher of the inning.

It was right-hander Kirby McMullen who served up a 1-0 fastball that Freeman feasted on. Freeman hammered the pitch well over the wall in left field, giving LSU its first lead in the 26th inning of the series.

Caleb Gilbert, who entered after LSU took the lead in the eighth, retired the six batters he faced for his third save of the year.

“You have to put up a zero after they put up the six spot in the eighth,” Gilbert said. “It’s crucial. It kept the momentum on our side.”

LSU returns to action Tuesday at home against Tulane before hosting Texas A&M in a series that begins Thursday. And, after avoiding a sweep with a dramatic win Sunday, it’ll take some confidence back home.

“It would’ve been a really difficult task keeping our kids’ chins up going into a tough week next week against Tulane and Texas A&M,” Mainieri said. “Now they’re feeling pretty good about themselves, which is a great thing.”

Follow Luke Johnson on Twitter, @ByLukeJohnson.