Le 27/11/2025 à 15:08, Jan Beulich a écrit : > On 27.11.2025 14:39, Teddy Astie wrote: >> Update p2m->need_flush if page was present before (requiring a tlb flush). >> This causes p2m->flush_tlb() to be now be reachable, make sure we call it >> only when set. > > I don't follow. Why would p2m->flush_tlb() not have been reachable? There are > other places where ->need_flush is set to true. > >> Signed-off-by: Teddy Astie <[email protected]> >> --- >> This change is important for the next patch. >> Would it be better to merge it with the next patch ? > > I'm inclined to say yes, but without understanding the description here I > cannot be sure. > > Hmm, wait. The sole place in x86 where the flag is set is in EPT code. So > do you perhaps mean that for NPT or shadow those call sites can now be > reached, and hence - with the hook being NULL there - checks need adding? > Then, by its title, the next patch actually may be making use of the hook, > so the checks then can be dropped again? >
Even with the next patch, in the shadow case, p2m->flush_tlb is still NULL as only HAP-NPT uses hap_p2m_tlb_flush(). > Jan -- Teddy Astie | Vates XCP-ng Developer XCP-ng & Xen Orchestra - Vates solutions web: https://vates.tech
