On the vanishing of cohomology of divisors on nonsingular surfaces