Bam Margera headed down to PA over the weekend to a fundraiser for his late friend and co-star, Ryan Dunn. The event was to raise money for Ryan’s widow, and Bam decided to rap none other than a Lil Wayne song to entertain the crowd.

Marisa Mendez

Bam surprised everyone at The Note in West Chester, PA on Saturday … when he hopped up on the stage, grabbed the mic … and busted out the song “Runnin.'”

We’re told everyone had a “great time” honoring Dunn and Zachary Hartwell … and the event raised more than $20k — all of which went to Zac’s wife.

WATCH THE VIDEO HERE