A pop star-turned-lawmaker is in “a lot of pain” after being beaten while in custody, the deputy speaker of Uganda’s parliament said Wednesday, as dozens of top musicians including Angelique Kidjo and Chris Martin condemned the “vicious” treatment.

Pressure was mounting on the government to free Kyagulanyi Ssentamu, also known as Bobi Wine, who has emerged as an influential critic of longtime President Yoweri Museveni after winning a parliament seat last year.

“We pledge to remain vigilant about his ongoing detention and to use our voices … to raise awareness about his case,” said the letter also signed by Chrissie Hynde, Femi Kuti, Brian Eno and other global musicians.

The government denies allegations that it tortured Ssentamu, and the military released a video of the 36-year-old opposition leader smiling during the visit by the deputy speaker, Jacob Oulanyah.

“This should not have happened,” Oulanyah said of the beating. “It was not necessary. But it happened.”

Despite being in pain, Ssentamu was in a “humorous” mood during the visit, Oulanyah told reporters.

Ssentamu is expected to make an appearance in a military court on Thursday. He has not been seen in public since Aug. 13, when he was campaigning in an election to choose a lawmaker in the northwestern town of Arua.

Museveni also was in Arua at the time, campaigning for a rival candidate who eventually lost. While the president was departing, authorities said, his motorcade was pelted with stones by people associated with Ssentamu and the candidate he backed, Kassiano Wadri.

Ssentamu’s driver was shot and killed, allegedly by security forces.

Ssentamu, who is charged with illegal possession of firearms, was arrested with four other opposition lawmakers, three of whom face treason charges. A fifth legislator, Francis Zaake, has been hospitalized with injures allegedly sustained during detention.

Security forces in recent days have violently put down street protests by Ugandans demanding Ssentamu’s release. Scores were arrested in riots in Kampala on Monday, and video by local broadcasters showed men in military uniforms beating up people, including at least two journalists.

Although Kampala was peaceful on Wednesday, riots were reported in the eastern town of Jinja, on Lake Victoria. Hundreds attended a special Mass in Uganda’s main Roman Catholic cathedral to pray for Ssentamu’s safety and that of other detained lawmakers.

“He isn’t supposed to be locked up. He’s supposed to be in hospital,” Ssentamu’s wife told the gathering.

Religious leaders have condemned the violence “in which lives are lost, people are barbarically arrested and tortured and property destroyed.”

In a statement late Wednesday, Museveni accused “unprincipled politicians” of luring youth into rioting. Responding to calls on social media to #FreeBobiWine, the president said he had no power to release Ssentamu. “Let us therefore wait for the courts and see what they decide.”

The lawmaker has quickly become popular with Uganda’s mostly young population. Candidates whom he has campaigned for have defeated both the ruling party and established opposition parties. Some of his followers urge him to run for president.

“He is a constant thorn in the flesh of Museveni,” said Rikki Stein, former manager for musician Fela Kuti, who said he met Ssentamu a couple of weeks ago and organized the open letter by musicians.

“Everybody responded literally immediately, horrified by what is taking place,” Stein said. “We’re hoping to make enough noise to get (Ssentamu) out.”

Museveni, a U.S. ally on regional security, took power by force in 1986 and has since been elected five times. Although he has campaigned on his record of establishing peace and stability, some worry that those gains are being eroded the longer he stays in power.

The 74-year-old Museveni is now able to seek re-election in 2021 because parliament passed legislation last year removing a clause in the constitution that had prevented anyone over 75 from holding the presidency. Ssentamu publicly opposed that decision.