TL;DR: Don't criticize the entity (and only that entity) for things that you let all other entities slide on.
Among other good advice, there's this important one: try to prove that you genuinely care about a general cause, NOT using that cause as an excuse to criticize the entity.
How do you do that? Simple. If you criticize everyone for issue X, it's fair game to criticize entity Y for the same. If you criticize only entity Y, but let everyone else's problems on issue X slide - often, far worse problems - then it can legitimately look like you are merely against entity Y in a biased way, even if issue X is a legitimate one in general.
Now, you may have lots of reasons why you only criticize entity Y. But given the prior of "entity Y is frequently discriminated against" stated in your question, the probability that the criticism is aimed at Y is due to such discrimination rises significantly.
As an example, let's say Dilbert criticizes Elbonia for hunting rare saber-toothed squirrels.
In theory, it's a valid concern - everyone wants to ensure that saber-toothed squirrels don't go extinct.
The rub is - Elbonia is responsible for 100 STS hunting incidents a year, the neighboring Shoulderistan is responsible for 100 more incidents, and the large Dudes' Republic of Brainia is responsible for 1000 incidents. Yet, Dilbert only criticizes Elbonia.
In that case, there's a legitimate reason to suspect that Dilbert just dislikes Elbonia. For if Dilbert really cared about saber-toothed squirrels, he'd have started his campaign with Brainia, or maybe every country where such hunting happens.
P.S. Yes, yes, whataboutism shmataboutism. Problem is, it's not a logical fallacy if it's not a fallacy in the first place. Quoting from my linked answer:
... sometimes a sober self-examination would reveal that the argument being made may, indeed, at its core, be hypocritical; and as such, "Appeal to Hypocrisy" in that situation isn't really a fallacy at all, but indeed a fully logical rebuttal.