Prince Rallies Baltimore 'It's Gonna Be All Right!'

5/11/2015 8:50 AM PDT

Prince bestowed words of hope Sunday on the city of Baltimore during his "Rally 4 Peace" show ... imploring the 14,000 fans to help fix the system.

People turning out for the show were encouraged to wear gray in support of Freddie Gray, whose death in police custody ... sparked the recent riots, and continued unrest in the city.

Prince played classics like "Let's Go Crazy" and "Purple Rain" ... as well as "Baltimore," which he wrote in response to the situation. In between songs, he offered words of encouragement ... "It's going to be all right. We are going to figure this thing out this time."

Gray's family was in attendance and took photos backstage with Beyonce and Jay Z.