On Sun, Feb 16, 2020 at 08:35:04AM +0200, Mike Rapoport wrote: > > BTW, with clarified scope of the AMD Erratum, I believe we can implement > > "collapse" for direct mapping. Willing to try? > > My initial plan was to use a pool of large pages to satisfy "secret" > allocation requests. Whenever a new large page is allocated for that pool, > it's removed from the direct map without being split into small pages and > then when it would be reinstated back there would be no need to collapse > it. It might be okay. But you likely will have to split 1G pages in direct mapping into 2M. Being able to repare the direct mapping is more generally useful. -- Kirill A. Shutemov