Cops can't always prove a suspect has committed the crime they actually care about, and in such cases will look for other crimes the suspect has committed that might be easier to prove. The most famous example is that Al Capone was convicted of tax evasion.
Marijuana possession is both very common and easy to prove, so it works well for that purpose. If a cop happens to come across it on a "good" person, they can always look the other way.
(not endorsing this approach, just speculating as to how police may view the situation)