\[ \boxed { \left ( {x}^{2}+1 \right ) {\frac {{\rm d}^{2}}{{\rm d}{x}^{2}}}y \left ( x \right ) +ax{\frac {\rm d}{{\rm d}x}}y \left ( x \right ) + \left ( a-2 \right ) y \left ( x \right ) =0} \]
Mathematica: cpu = 0.025503 (sec), leaf count = 82 \[ \left \{\left \{y(x)\to c_1 \left (x^2+1\right )^{\frac {2-a}{4}} P_{\frac {a-4}{2}}^{\frac {a-2}{2}}(i x)+c_2 \left (x^2+1\right )^{\frac {2-a}{4}} Q_{\frac {a-4}{2}}^{\frac {a-2}{2}}(i x)\right \}\right \} \]
Maple: cpu = 0.062 (sec), leaf count = 36 \[ \left \{ y \left ( x \right ) ={\it \_C1}\, \left ( {x}^{2}+1 \right ) ^{1 -{\frac {a}{2}}}+{\it \_C2}\, {\mbox {$_2$F$_1$}(1,{\frac {a}{2}}-{\frac {1}{2}};\,{\frac {3}{2}};\,-{x}^{2})} x \right \} \]