We clarify topology of $^3P_2$ superfluids which are expected to be realized in the inner cores of neutron stars and cubic odd-parity superconductors. $^3P_2$ phases include uniaxial/biaxial nematic phases and nonunitary ferromagnetic and cyclic phases. We here show that all the phases are accompanied by different types of topologically protected gapless fermions: Surface Majorana fermions in nematic phases and a quartet of (single) itinerant Majorana fermions in the cyclic (ferromagnetic) phase. Using the superfluid Fermi liquid theory, we also demonstrate that dihedral-two and -four biaxial nematic phases are thermodynamically favored in the weak coupling limit under a magnetic field. It is shown that the tricritical point exists on the phase boundary between these two phases and may be realized in the core of realistic magnetars. We unveil the intertwining of symmetry and topology behind mass acquisition of surface Majorana fermions in nematic phases.