Shaming all men for what a (bad) subset of men do is sexist. Shaming all white men for what a (bad) subset of white men do is sexist and racist.
Shaming all black men because some black men are criminals is racist.
Highlighting that the (good) majority should call out the (bad) minority is reasonable. Blaming the whole is not. It's true regardless of the target race, or sex, or gender, etc.