  Tolman VII solution [Phys. Rev. 55 (4), 364 (1939)] is an exact analytic
solution to the Einstein field equations describing the space-time of a static
spherically symmetric distribution of matter. The solution has been shown to be
capable of describing the interior of compact objects like neutron stars.
Generalized [Phys. Rev. D 92(12), 124005 (2015)] and modified [Phys. Rev. D
99(12), 124029 (2019)] versions of the solution are also available in the
literature, which have been subsequently developed to accommodate a wide range
of neutron star EOS. The stability of the modified Tolman VII solution has
recently been analyzed by Posada et al [Phys. Rev. D 103(10), 104067 (2021)],
which provides a critical value of the adiabatic index above which the stellar
configuration becomes unstable against radial oscillations. In this paper,
making use of the generalized version of the Tolman VII solution, we prescribe
an upper bound on the compactness ($M/R$) beyond which the star becomes
unstable against radial oscillations. Our study brings to attention the role of
model parameters in the generalized Tolman VII solution. The analysis also
provides new insight into the role of inhomogeneity of the matter distribution
vis-a-vis equation of state (EOS) on the compactness of a relativistic star.
