Return Path of Bypass Capacitor in a PCB with 2 Grounds
A capacitor placed on a line (to ground) to restrict "bad stuff coming out" is grounded locally but, on the other hand, protecting "bad stuff getting in" means it gets grounded local to what it protects. Sometimes both are needed.

Taking it one small step further means adding a series resistor to the control line to further enhance the protection. In either case you would have the resistor closest to the source of the signal.

Sometimes this just cannot be done (on those occasions when the control line is actively involved in a control loop). The main recourse here is to use a differential amplifier to transfer the good voltage at the noisy ground (the source) to be a good voltage at the clean end (where it needs to be inputted).

And, of course, there are those situations when a control voltage needs to pass from one completely different sub-system to another and there are several ways such as digitizing the signal and transmitting via an opto coupler or an isolation amplifier.