The only solution to that is to tear down the walls compartmentalizing different communities along race. When they are systematically see to be like us racism evaporates. In this example, his prejudice was not an impediment to that process occurring. What is necessary, in terms of state intervention, is to counter the formation of ghettos, of separate communities, along race. Or indeed along many other artificial distinctions. It doesn't even require any kind of anti-racist policy, (with all the political controversy and division it causes), merely a policy of providing, enforcing, a standard of living that allows for the presently separate communities (including those naturally formed among large groups of immigrants) to mix in. Accessible basics of living (health care, education, habitation) equally for al the population goes a long way towards that.
Very, very often the formation of ghettos is due to the economic segregation of newcomers. Opening the doors to immigrants only to have them take on the role of lower strata of society is social poison: bereft of options they band together for support instead of spreading and intermingling, and being poor and apparently homogeneous group they are looked down upon by the rest of the population and associated with the traditionally dangerous traits of the poorer strata: they get described as opportunists (desperate...), thieves, amoral, uneducated, whatever...
You'll notice that the wealthy immigrants do not get lumped into the same category. Not even the russian oligarchs... it's (not solely but) to a large degree a class problem, especially in the cities where you can have immigrants prejudiced against other immigrants further down the ladder.
Ultimately there is always a limit to the number of immigrants that can enter without causing the creation of a poorly integrated and supported underclass.
And, risking the wrath of the woke left, I'm also saying the state should enforce whatever happens to be considered the most important social norms against newcomers who refuse to accept them. It is bad policy to, say, pass special laws legalizing polygamy among a small portion of the population just because you have an immigrant community from societies where it is practiced and who demand it. If some "new sum-community" makes special demands, are they really acceptable to the majority? Substitute polygamy for any number of other "cultural things". The so-called "multi-culturalism" was always very dangerous ground: it can create racism and other -isms where there was none. This is the other major part of the problem.
The two together are what really problems, and the two can be tackled only when acknowledged and discusses without taboos. Just demanding "cease your racism!" from random people will not do it.
I still wonder at how often the racism thing is raised in UK politics. Considering the number of foreigners the UK is already absorbing the problems it has were to be expected, imo it's actually not mishandling them as badly as some other european countries.
Edit: I guess that the issues come up in the UK precisely because it hosts so many immigrants inevitably pushed into the lower rungs of the economic scale. Having also some extremely wealthy ones buying prime property does nothing to endear "foreigners" in general to the citizens who in consequence feel priced out of the best spots. And those take it out on the foreigners they can reach and attack.