Updated

Jordan Danks hit his first home run of the season and it proved to be the difference-maker, as his two-out, solo shot in the 11th gave the White Sox the go-ahead run in their 2-1 victory over the Kansas City Royals on Monday.

Alexei Ramirez hit a game-tying bases loaded infield single with two outs in the ninth to send the game to extras. Starter Chris Sale tossed 7 1/3 solid innings for Chicago, which halted a two-game losing skid to take the finale of this three-game set.

"Being able to pull off a win like that, especially when we're struggling, it's big time," Danks said.

Jesse Crain (1-1) picked up the win after retiring the side in the 10th. Addison Reed earned his 11th save of the season with a perfect 11th.

Billy Butler drove in the lone run in the first inning for Kansas City, which had won seven of its last eight at home versus the White Sox.

James Shields tossed eight shutout innings and allowed two hits and two walks while striking out a season-high nine batters. Greg Holland blew the save after allowing three straight singles in the ninth and eventually, Ramirez' game-tying infield single.

Kelvin Herrera (2-3) absorbed the loss thanks to serving up Danks' solo blast to right-center.

Holland relieved Shields at the start of the ninth and quickly ran into trouble. Jeff Keppinger, Alex Rios and Adam Dunn all smacked singles to load the bases with no outs. Holland briefly got out of the jam, as the next batter Paul Konerko, grounded a ball back to the mound for a rare, 1-2-3 double play.

Holland then intentionally walked Conor Gillaspie to load the bases again. Ramirez, though, tied the game with a soft liner up the middle to score Rios. On the play, Royals shortstop Chris Getz collected the ball and threw out Danks, who was easily tagged out after trying to advance to home, to end the inning.

"I didn't get ahead of the first three hitters," Holland said. "I gave up some hits. I feel like once the bases were loaded I executed pretty well. It was just one of those things, where you fall behind and load bases with no one out, you're not going to get out of it as often as you'd like."

It was a pitching duel for most of the contest, as both starters had their A game.

Sale allowed one run on six hits to go along with five strikeouts, while Shields stifled the White Sox through the first five innings, failing to allow a hit. The righty retired the 14-of-17 batters he faced, yielding one walk and a hit batter.

In the sixth, however, DeWayne Wise poked a line drive to shallow right and Jeff Francoeur dove for the ball head first, but it bounced out of his glove to give Chicago its first hit.

Sale, meanwhile, wasn't too shabby either. Following Alex Gordon's second inning single, Sale retired 15 consecutive batters over the next five-plus innings before Salvador Perez doubled.

Butler put the hosts on the board early in the first with a double down the left-field line. Alex Gordon, who hit an infield single to leadoff the contest, hustled around the bases from first on Butler's two-bagger to make it 1-0.

Game Notes

The White Sox announced on Monday that starting pitcher Gavin Floyd will have surgery to repair the ulnar collateral ligament and torn flexor muscle in his right elbow and miss the remainder of the season ... Chicago had more hits in the ninth (3) than in the first eight innings combined ... Shields hasn't earned a win over the White Sox since April 19, 2011 ... Danks' homer was just the second of his MLB career ... Friday's opening game was postponed due to freezing rain.