This function does not need to accept a page and requiring it to is unnecessary and misleading. make_[writable, readable]_device_private_entry() must be passed a PMD-aligned PFN as they immediately used to obtain a softleaf PMD entry and the same argument applies to folio_add_[anon, file]_rmap_pmd(). While we are here, update a VM_BUG_ON() to a VM_WARN_ON_ONCE(). No functional change intended.
Showing the changes to include (1 of 3 files). Show all
Unified · Split
| @@ -325,8 +325,8 @@ struct page_vma_mapped_walk; · 324 unmodified lines | ||
| 325 | 325 | extern int set_pmd_migration_entry(struct page_vma_mapped_walk *pvmw, |
| 326 | 326 | struct page *page); |
| 327 | 327 | |
| 328 | −extern void remove_migration_pmd(struct page_vma_mapped_walk *pvmw, | |
| 329 | − struct page *new); | |
| 328 | +void remove_migration_pmd(struct page_vma_mapped_walk *pvmw, | |
| 329 | + struct folio *folio); | |
| 330 | 330 | |
| 331 | 331 | extern void pmd_migration_entry_wait(struct mm_struct *mm, pmd_t *pmd); |
| 332 | 332 | |
| @@ -346,7 +346,7 @@ static inline int set_pmd_migration_entry(struct page_vma_mapped_walk *pvmw, · 13 unmodified lines | ||
| 346 | 346 | } |
| 347 | 347 | |
| 348 | 348 | static inline void remove_migration_pmd(struct page_vma_mapped_walk *pvmw, |
| 349 | − struct page *new) | |
| 349 | + struct folio *folio) | |
| 350 | 350 | { |
| 351 | 351 | BUILD_BUG(); |
| 352 | 352 | } |