US Representative Edward J. Markey disinvited Tuesday a Confederate flag ­defender, former television star, and onetime House colleague from playing music at Markey’s Washington, D.C., fund-raiser hours before it was scheduled to begin.

Markey’s US Senate campaign said the Malden Democrat was “completely unaware” that former Georgia Democratic congressman Ben Jones, who played ­mechanic Cooter Davenport on the “Dukes of Hazzard” television show, has long been an ardent proponent of the Stars and Bars as a symbol of Southern culture.

Jones, who describes himself as a veteran of the civil rights movement, publicly sparred in 2002 with former Virginia governor Douglas Wilder over Jones’s use of the flag in his campaign for a Virginia congressional seat.

The same year, Markey donated $500 to Jones’s campaign, one of two personal campaign donations Markey has made to federal candidates since 1997, according to Federal Election Commission records.

Jones was scheduled to be the featured musical guest at a fund-raiser at the home of a mutual friend. Shortly after the Globe inquired Tuesday about Markey’s position on Jones’s advo­cacy for the Confederate flag, a Markey campaign spokesman said the Malden Democrat had disinvited Jones.

“Ed Markey was not aware of Ben Jones’ advocacy for the confederate flag; he strongly disagrees with it and after learning about Jones’ comments, we asked him not to be part of tonight’s event,” the spokesman, Andrew Zucker, said in an e-mail. “Ed believes such Confederate relics are highly offensive and should not be displayed in public settings, period.”

Jones served two terms in Congress from 1989 to 1993, representing a Georgia district and sitting in the same Democratic caucus as Markey.

His position on the flag made national news during his 2002 campaign against US Representative Eric Cantor, now the House majority leader. Jones occasionally rode during parades in the Dodge Charger from “Dukes of Hazzard,” ­Confederate flag and all, drawing a rebuke from Wilder, the first African-American elected governor in the United States.

Jones told the Globe he had received a call Tuesday from a Markey staff member “insulting me, my beliefs, my politics, my heritage, and everything else, and I guess my musicianship.”

“I basically told the guy to fold it four ways and put it where the sun don’t shine,” Jones said in a phone interview.

Jones said he had been shot at and jailed during his civil rights activism and questioned why his unapologetic support for what he called an artifact of regional history should prompt a political backlash.

“The fact that this is regarded as a political liability means that they think it’s going to be a close race,” he said. Still, he said, he would vote for Markey if he lived in Massachusetts.

Jones’s recent defense of the Confederate flag includes a letter posted on his website ­denouncing NASCAR last year for preventing the car featured in “Dukes of Hazzard” from appear­ing at a track event.

NASCAR canceled a planned parade lap with golfer Bubba Watson behind the wheel of the “General Lee” at Phoenix International Raceway due to worries about reactions to the car’s roof, which features the Civil War banner of the South.

Jones wrote that NASCAR had “chosen to dishonor those Southerners who fought and died in that terrible conflict by caving to ‘political correctness’ and the uninformed concerns of corporate sponsors.”

“This is also an extraordinary insult to rural Southerners, who are NASCAR’s oldest and most fervent fan base, and it sends a message against ­inclusion and against the need for diversity,” wrote Jones. “Many of us who are descended from ancestors who fought for the South see this as a crude dishonoring of our kinfolks and our heritage.”

According to his website, cootersplace.com, Jones has ­remained politically active. At the Markey fund-raiser, he was scheduled to appear with ­Cooter’s Garage Band.

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.

Thanks & Welcome to Globe.com

You now have unlimited access for the next two weeks.

BostonGlobe.com complimentary digital access has been provided to you, without a subscription, for free starting today and ending in 14 days. After the free trial period, your free BostonGlobe.com digital access will stop immediately unless you sign up for BostonGlobe.com digital subscription. Current print and digital subscribers are not eligible for the free trial.