Feedback from a central supermassive black hole is an essential component of galaxy evolution models. Without it, those models cannot obtain massive galaxies and galaxy clusters with the observed properties. However, the black-hole feedback mechanism remains mysterious. Somehow, accretion of matter onto the central black hole of a massive galaxy becomes precisely tuned so that it regulates radiative cooling and condensation of gas in a volume many orders of magnitude larger than the black-hole’s gravitational zone of influence. I will discuss how the required coupling can arise through condensation and precipitation of cold clouds out of a galaxy’s circumgalactic medium, through a mechanism in which the ambient entropy gradient acts as a valve that regulates black-hole feedback.