CHICAGO — Trevor Bauer took a step toward returning to the Indians' rotation for the postseason by tossing four effective innings, but the Chicago White Sox overcame a two-run, ninth-inning deficit to win 5-4 Tuesday night.

Carlos Carrasco (16-10) followed Bauer with his second relief appearance this season. Carrasco tossed one-hit, shutout ball through four innings and entered the ninth with a 4-2 lead before the White Sox scored three times and snapped a three-game losing streak.

The White Sox need to win one of their last five games to avoid their first 100-loss season since 1970, when they went 56-106.

Daniel Palka's game-ending single up the middle with one out drove in two runs and capped the rally.

Yoan Moncada led off the ninth with a walk, Adam Engel and Yolmer Sanchez followed with singles that cut the score to 4-3. Leury Garcia's sacrifice bunt advanced Engel to third and Sanchez to second, then Palka delivered game-winning hit.

Bauer allowed two runs — on Avisail Garcia's career-high-19th homer in the first — in his second start since suffering a stress fracture in his right leg on Aug. 11. The right-hander also allowed four singles, struck out four and walked none. He threw 43 strikes in the 60-pitch limit set by manager Terry Francona.

Yan Gomes hit his 16th homer and Yonder Alonso had two RBI for the Indians in game that was delayed 51 minutes at the start due to rain. The Indians, who have won the AL Central three consecutive years, will open a division series next week at the winner of the AL West.

White Sox starter James Shields allowed four runs on six hits and four walks in six innings. Reliever Ian Hamilton (1-2) got one out in the ninth to earn the win

Bauer was limited to 1 1/3 innings and 34 pitches against the Boston Red Sox last Friday in his first outing since returning from the disabled list. He allowed no runs on two hits and walked one against the Red Sox.

An All-Star for the first time in 2018, Bauer was in the midst of his best season — and on a roll — when Jose Abreu's liner hit him in the leg in the seventh inning of a 3-1 Indians win at Guaranteed Rate Field last month.

When the 27-year-old righty landed on the disabled list on Aug. 14, he was 12-6 with a 2.22 ERA, and 4-0 with 1.05 ERA in his past four starts. Including his Aug. 11 win over the White Sox, Bauer had thrown 100 or more pitches in each of his first 25 starts this season.

In this one, Garcia drove a belt-high breaking pitch from Bauer into the left-center bleachers on a 2-2 count with two outs in the first to put the White Sox ahead 2-0.

The Indians scored three runs with two outs in the third off Shields for a 3-2 lead. Ramirez drove in the first run with a sharp single. After the Indians loaded the bases, Alonso's single drove in two more.

Bauer allowed singles to Leury Garcia and Daniel Palka with two outs in the bottom half, but escaped on Avisail Garcia' soft comebacker.

Gomes' solo shot in the fourth made it 4-2.

Trainer's room

Indians: Outfielder Michael Brantley left the game in the sixth with a right calf contusion.

Up next

Indians right-hander Shane Bieber (10-5, 4.80) starts on Wednesday. White Sox manager Rick Renteria didn't name a starter before the game and said a bullpen day was a possibility.