First movie to negatively portray the police?

Some films not already mentioned:

Double Crossed (1917) - Pre-Pre-Code story of corrupt cop coercing dude who stole necklace out of desperation into more thievery to help a politician’s campaign.

The Beast of the City (1932) - Police Chief goes after a mob using non-standard (and excessively violent) methods…and he’s the good guy!

I Wake Up Screaming (1941) - Corrupt cop tries to pin a showgirl’s murder on an innocent dude.

Where the Sidewalk Ends (1950) - Corrupt cop tries to cover up his misdeeds.

Rogue Cop (1954) - Cop on the take turns against the mob after they clip his cop brother.

The Case Against Brooklyn (1958) - Corruption in the NY police force leads the DA to form a special squad of rookie cops to find the corrupt ones.

The worlds first feature length film, The Story Of The Kelly Gang (1906) gives a sympathetic view of Ned Kelly and his gang and portrays the police as villains

It occurs to me that even during the era when police were almost always depicted as the good guys, they were still considered brusque in their treatment of wrongdoers and scary to anyone who might even innocently fall afoul of the law. And prisons and prison guards were worse.

The Wrong man.
1956
Henry Fonda

Even in Disney films: