A man who was stabbed to death on the CTA Red Line over the weekend was trying to stop his alleged killer from attacking another passenger, Cook County prosecutors said Wednesday.

Tony Polk killed 54-year-old Troy Johnson during a struggle that began inside a Red Line car and ended with the convicted felon stabbing Johnson in the chest as the pair tumbled onto an L platform in Chinatown Saturday, Assistant State’s Attorney James Murphy said during a bond hearing.

Polk, 40, and a female acquaintance had boarded the train, and Polk exchanged words with a person sitting near him, Murphy said. After moving to a seat across the aisle from his friend, Polk allegedly lunged at the woman and struggled with her over a folding knife she had tucked in her belt.

Polk, snatching away the knife, then grabbed a passenger seated across from Johnson and “put the knife to him,” Murphy said. The woman, who had cut her hand during the struggle with Polk, fled the train car. Johnson, who’d been holding a beer, jumped up to help the man being held at knifepoint by Polk, Murphy said. Polk and Johnson struggled, and Johnson managed to push Polk off the train and onto the platform. But Polk lunged and “repeatedly stabbed” Johnson, who was wounded in the chest and arm, Murphy said. Johnson died at the scene.

Surveillance video on the train and platform captured the deadly attack, Murphy said.

Meanwhile, the woman who was with Polk had gone to a nearby restaurant to seek help for the cut on her hand. She then called Polk, who told her he had “beat up” Johnson, Murphy said. Polk and the woman met up on Archer Avenue, where Polk gave the woman the knife back, Murphy said. The woman told police at that time, the knife had no blood on it. The pair then went to a Green Line station, where the woman cut Polk’s shirt to make a bandage for a wound he’d suffered.

The woman eventually saw reports that a man had been stabbed to death on the Red Line. When she confronted Polk about the attack, he “said he did not know he did that,” Murphy said.

After seeing her picture on the news Sunday, the woman called police from a Red Line station at Fullerton, and asked police to pick her up so she could “clear her name”— hiding the knife in a planter at the CTA station before police picked her up. The woman later told police where to find the knife and Polk’s shirt, which he had thrown in the trash after it was cut to make a bandage, Murphy said.

Polk was arrested Monday at his South Shore home.

Polk, who was a month away from completing his parole for an aggravated robbery conviction, was ordered held without bond Wednesday on a charge of first-degree murder.

Court records show that Polk has been arrested dozens of times since 1997 on charges that include drug possession, aggravated assault, unlawful use of a weapon, battery, robbery and domestic battery.

Prior to being taken into custody Monday, he’d already been arrested twice in 2019. In January, he was arrested on retail theft charges in the South Loop. In June, he was charged with assault after being arrested in South Shore.

Prison records show that Polk has four previous felony convictions — three of which were for robbery.

In December 2014, Polk was sentenced to six years in prison after he pleaded guilty to an armed robbery in the 6800 block of South Jeffrey. He was given credit for the 388 days he spent at the Cook County Jail and he was released from prison on parole on March 7, 2019, prison records show.

Polk is no stranger to high-profile criminal cases in Chicago.

In 2016, he testified in the criminal trial of Donnell Flora, who was convicted of giving a gun to his niece, who later shot and killed 14-year-old Endia Martin.

Polk said that, while he and Flora were held in the Cook County Jail in 2014, Flora admitted to him that he gave his niece the gun, with Flora saying of the teen: “That b---- got what she deserved.”