On 23/09/20 19:26, Sean Christopherson wrote:
>       /*
>        * Flush before LAUNCH_UPDATE encrypts pages in place, in case the cache
>        * contains the data that was written unencrypted.
>        */
>       sev_clflush_pages(inpages, npages);
> 
> there's nothing in the comment or code that even suggests sev_clflush_pages() 
> is
> conditional, i.e. no reason for the reader to peek at the implemenation.
> 
> What about:
> 
>       /*
>        * Flush (on non-coherent CPUs) before LAUNCH_UPDATE encrypts pages in
>        * place, the cache may contain data that was written unencrypted.
>        */

Sounds good.

Paolo

Reply via email to