Function report |
Source Code:mm\migrate.c |
Create Date:2022-07-28 15:58:28 |
Last Modify:2022-05-20 09:53:13 | Copyright©Brick |
home page | Tree |
Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Replace the page in the mapping.* The number of remaining references must be:* 1 for anonymous pages without a mapping* 2 for pages with a mapping* 3 for pages with a mapping and PagePrivate/PagePrivate2 set.
Proto:int migrate_page_move_mapping(struct address_space *mapping, struct page *newpage, struct page *page, int extra_count)
Type:int
Parameter:
Type | Parameter | Name |
---|---|---|
struct address_space * | mapping | |
struct page * | newpage | |
struct page * | page | |
int | extra_count |
403 | expected_count = expected_page_refs(mapping, page) + extra_count |
405 | If Not mapping Then |
407 | If page_count(page) != expected_count Then Return -EAGAIN |
413 | If PageSwapBacked(page) Then __SetPageSwapBacked(newpage) |
422 | xas_lock_irq( & xas) |
424 | xas_unlock_irq( & xas) |
425 | Return -EAGAIN |
428 | If Not page_ref_freeze(page, expected_count) Then |
429 | xas_unlock_irq( & xas) |
430 | Return -EAGAIN |
439 | page_ref_add(newpage, hpage_nr_pages(page)) |
440 | If PageSwapBacked(page) Then |
442 | If PageSwapCache(page) Then |
443 | SetPageSwapCache(newpage) |
444 | set_page_private(newpage, page_private(page)) |
446 | Else |
447 | VM_BUG_ON_PAGE(PageSwapCache(page), page) |
452 | If dirty Then |
453 | ClearPageDirty(page) |
454 | SetPageDirty(newpage) |
461 | When i < HPAGE_PMD_NR cycle |
474 | xas_unlock( & xas) |
490 | If PageSwapBacked(page) && Not PageSwapCache(page) Then |
494 | If dirty && mapping_cap_account_dirty(mapping) Then |
Name | Describe |
---|---|
migrate_page | Common logic to directly migrate a single LRU page suitable for* pages that do not use PagePrivate/PagePrivate2.* Pages are locked upon entry and exit. |
__buffer_migrate_page | |
iomap_migrate_page |
Source code conversion tool public plug-in interface | X |
---|---|
Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |