Let $R$ be a commutative Noetherian ring, $\mathfrak {a}$ an ideal of $R$, $M$ an $R$-module and $t$ a non-negative integer. In this paper we show that the class of minimax modules includes the class of $\mathcal {AF}$ modules. The main result is that if the $R$-module ${\rm Ext}^t_R(R/\mathfrak {a},M)$ is finite (finitely generated), $H^i_\mathfrak {a}(M)$ is $\mathfrak {a} $-cofinite for all $i<t$ and $H^t_\mathfrak {a}(M)$ is minimax then $H^t_\mathfrak {a}(M)$ is $\mathfrak {a} $-cofinite. As a consequence we show that if $M$ and $N$ are finite $R$-modules and $H^i_\mathfrak {a}(N)$ is minimax for all $i<t$ then the set of associated prime ideals of the generalized local cohomology module $H^t_\mathfrak {a}(M,N)$ is finite.