Ideally grind it down to bare shiny metal where the rust. Then prime and paint (either the whole panel or touch-up) Alternatively a rust converter could be used with some slight rust remaining if it's hard to grind off. You need a good rust converter, the best one that I knew of was banned in California at least, not sure if it's available elsewhere in the US.