We address the fundamental question of matching the rest-frame K -band luminosity function ( LF ) of galaxies over the Hubble time using semi-analytic models , after modification of the stellar population modelling . We include the Maraston evolutionary synthesis models , that feature a higher contribution by the Thermally Pulsating - Asymptotic Giant Branch ( TP-AGB ) stellar phase , into three different semi-analytic models , namely the De Lucia and Blaizot version of the Munich model , morgana and the Menci model . We leave all other input physics and parameters unchanged . We find that the modification of the stellar population emission can solve the mismatch between models and the observed rest-frame K -band luminosity from the brightest galaxies derived from UKIDSS data at high redshift . For all explored semi-analytic models this holds at the redshifts - between 2 and 3 - where the discrepancy was recently pointed out . The reason for the success is that at these cosmic epochs the model galaxies have the right age ( \sim 1 Gyr ) to contain a well-developed TP-AGB phase which makes them redder without the need of changing their mass or age . At the same time , the known overestimation of the faint end is enhanced in the K -band when including the TP-AGB contribution . At lower redshifts ( z < 2 ) some of the explored models deviate from the data . This is due to too short merging timescales and inefficient ’ radio-mode ’ AGN feedback . Our results show that a strong evolution in mass predicted by hierarchical models is compatible with no evolution on the bright-end of the K -band LF from z=3 to the local universe . This means that , at high redshifts and contrary to what is commonly accepted , K -band emission is not necessarily a good tracer of galaxy mass .