Cough syrups simply suppress Jimmy’s urge to do so. This is not necessarily a good thing, since coughing keeps unwanted substances like dust and germs out of the airway. In asthma, especially, the cough helps by bringing up excess mucus. As a rule of thumb, if Jimmy is coughing without complaint, don’t interfere with his expectoration process.
If the cough is quite disabling, however, you may have to consider a cough suppressant. The over-the-counter varieties have a limited effect, which wears off after a couple of hours. If possible, choose a plain suppressant without an expectorant or a decongestant; these additives have potential side effects and few benefits. Prescription cough syrups are more efficient, especially when they contain codeine. A remote cousin of morphine, codeine can be habit-forming in adults (especially those who take it more for the side effects than for a cough), but this addiction is not an issue in kids. Used in appropriate doses, codeine is perfectly safe.
My approach is to prescribe cough syrups sparingly, but when I do prescribe them, I use the ones that really work. The codeine-based syrups are the most effective, and they have relatively minimal side effects.