KernelNewbies
  • Comments
  • Immutable Page
  • Menu
    • Navigation
    • RecentChanges
    • FindPage
    • Local Site Map
    • Help
    • HelpContents
    • HelpOnMoinWikiSyntax
    • Display
    • Attachments
    • Info
    • Raw Text
    • Print View
    • Edit
    • Load
    • Save
  • Login

Kernel Hacking

  • Frontpage

  • Kernel Hacking

  • Kernel Documentation

  • Kernel Glossary

  • FAQ

  • Found a bug?

  • Kernel Changelog

  • Upstream Merge Guide

Projects

  • KernelTasklists

  • KernelJanitors

  • KernelMentors

  • KernelProjects

Community

  • Why a community?

  • Regional Kernelnewbies

  • Personal Pages

  • Upcoming Events

References

  • Mailing Lists

  • Related Sites

  • Programming Links

Wiki

  • Recent Changes

  • Site Editors

  • Side Bar

  • Tips for Editors

  • Hosted by WikiWall

Navigation

  • RecentChanges
  • FindPage
  • HelpContents
Revision 2 as of 2024-05-28 18:40:51
KernelNewbies:
  • MatthewWilcox
  • Memdescs
  • Path

How do we get to memdescs in a series of bisectable, small and reviewable steps?

From here (May 2024), finish converting all filesystems to folios. This is very parallel. Once that has finished, rename ->mapping to ->__folio_mapping and ->index to ->__folio_index

In parallel with this, pull struct page apart as has already been done for ptdesc and slab.

Once all this has landed, we can start dynamically allocating the various memdescs and point to them from every page's compound_head (instead of just the tail page).

Then we can shrink struct page to 32 bytes,

struct page {
    unsigned long flags;
    union {
        struct list_head buddy_list;
        unsigned long compound_head;
    };
    unsigned long private;
};

The next step is to shrink struct page to 16 bytes,

struct page {
    union {
        struct list_head buddy_list;
        struct {
            unsigned long memdesc;
            unsigned long private;
        };
    };
};

This will involve changes to page_zone(), page_to_nid() and so on.

After this, we can start working on removing accesses to page->private from device drivers. When that is finished, we can explore the various options presented in MatthewWilcox/BuddyAllocator

  • MoinMoin Powered
  • Python Powered
  • GPL licensed
  • Valid HTML 4.01