Cheating can be prevented by ensuring that the person giving and grading the test is not the same as the person preparing the students for the test. Likewise, the 'macro'-problem can be prevented by designing good measurement systems. If performance is measured as comparing results of individual students across time, then it doesn't matter whether a student comes from a 'disadvantaged' background. The same goes for innate talent: we can design a measurement that rewards any improvement in significantly less talented children sufficiently high to ensure that teachers are motivated in teaching them.