When Frank Serpico, the most famous police whistleblower of his generation, reflected on years of law-enforcement corruption in the New York Police Department, he assigned substantial blame to a commissioner who failed to hold rank-and-file cops accountable. That's the classic template for police abuse: misbehaving cops are spared punishment by colleagues and bosses who cover for them.
There are, of course, police officers who are fired for egregious misbehavior by commanding officers who decide that a given abuse makes them unfit for a badge and gun. Yet all over the U.S., police unions help many of those cops to get their jobs back, often via secretive appeals geared to protect labor rights rather than public safety. Cops deemed unqualified by their own bosses are put back on the streets. Their colleagues get the message that police all but impervious to termination.
That isn't to say that every officer who is fired deserves it, or that every reinstated cop represents a miscarriage of justice. In theory, due process before a neutral arbiter could even protect blue whistleblowers from wrongful termination. But in practice, too many cops who needlessly kill people, use excessive force, or otherwise abuse their authority are getting reprieves from termination.