We analyze the presence of exponential dichotomy (ED) and of global existence of Weyl functions $M^\pm$ for one-parametric families of finite-dimensional nonautonomous linear Hamiltonian systems defined along the orbits of a compact metric space, which are perturbed from an initial one in a direction which does not satisfy the classical Atkinson condition: either they do not have ED for any value of the parameter; or they have it for at least all the nonreal values, in which case the Weyl functions exist and are Herglotz. When the parameter varies in the real line, and if the unperturbed family satisfies the properties of exponential dichotomy and global existence of $M^+$, then these two properties persist in a neighborhood of 0 which agrees either with the whole real line or with an open negative half-line; and in this last case, the ED fails at the right end value. The properties of ED and of global existence of $M^+$ are fundamental to guarantee the solvability of classical minimization problems given by linear-quadratic control processes.