Magnesium (Mg) is abundant in humans. Studies have shown that Mg2+ significantly affects physiological processes such as osteogenesis, osteoblast adhesion and motility, immunomodulation, and angiogenesis. Mg-based alloy porous scaffolds have attracted increasing attention because of their degradability and mechanical properties. Hence, wire-cut EDM was used to fabricate porous scaffolds. In addition, fluoride treatment afforded an MgF2 coating, and racemic polylactic acid PDLLA was used as the carrier of rhBMP-2, which was evenly coated on the surface of the passivated porous alloy scaffold to slowly release growth factors and slow down the degradation rate. The rat femoral condyle defect model experiment was performed to study the in vivo bone regeneration capacity of porous scaffolds and compare the differences in the healing effect with or without rhBMP-2. The enhanced corrosion resistance of the porous scaffold was confirmed through in vitro immersion experiments. Micro-CT implied that porous scaffold with rhBMP-2 induced new bone formation and the new bone formation along the pores, as well as the histological examination in vivo. In summary, the porous scaffold promotes bone formation and has great potential for clinical translation.