  We study an extended Aubry-Andr{\'e}-Harper model with simultaneous
modulation of hopping, on-site potential, and $p$-wave superconducting pairing.
For the case of commensurate modulation of $\beta = 1/2$ it is shown that the
model hosts four different types of topological states: adiabatic cycles can be
defined which pump particles, two types of Majorana fermions, or Cooper pairs.
In the incommensurate case we calculate the phase diagram of the model in
several regions. We characterize the phases by calculating the mean inverse
participation ratio and perform multi-fractal analysis. In addition, we
characterize whether the phases found are topologically trivial or not. We find
an interesting critical extended phase when incommensurate hopping modulation
is present. The rise between the inverse participation ratio in regions
separating localized and extended states is gradual, rather than sharp. When,
in addition, the on-site potential modulation is incommensurate, we find
several sharp rises and falls in the inverse participation ratio. In these two
cases all different phases exhibit topological edge states. For the
commensurate case we calculate the evolution of the Hofstadter butterfly and
the band Chern numbers upon variation of the pairing parameter for zero and
finite on-site potential. For zero on-site potential the butterflies are
triangular-like near zero pairing, when gap-closure occurs, they are
square-like, and hexagonal-like for larger pairing, but with the Chern numbers
switched compared to the triangular case. For the finite case gaps at quarter
and three-quarters filling close and lead to a switch in Chern numbers.
