On Wed, Sep 02, 2020 at 02:06:13PM -0400, Zi Yan wrote: > From: Zi Yan <ziy@xxxxxxxxxx> > > When depositing page table pages for 1GB THPs, we need 512 PTE pages + > 1 PMD page. Instead of counting and depositing 513 pages, we can use the > PMD page as a leader page and chain the rest 512 PTE pages with ->lru. > This, however, prevents us depositing PMD pages with ->lru, which is > currently used by depositing PTE pages for 2MB THPs. So add a new > pagechain container for PMD pages. > > Signed-off-by: Zi Yan <ziy@xxxxxxxxxx> Just deposit it to a linked list in the mm_struct as we do for PMD if split ptl disabled. -- Kirill A. Shutemov