diff options
author | Miaohe Lin <linmiaohe@huawei.com> | 2024-06-12 10:18:32 +0300 |
---|---|---|
committer | Andrew Morton <akpm@linux-foundation.org> | 2024-07-04 05:30:11 +0300 |
commit | 3a78f77fd1fb82c32cb7971a8a97c5cbc83ab69e (patch) | |
tree | a2efb94c5c16942d15639ec2dcca6fef584b74d3 /mm/internal.h | |
parent | 28eab7d4e7b4fefed7122d49eb8148c623540739 (diff) | |
download | linux-3a78f77fd1fb82c32cb7971a8a97c5cbc83ab69e.tar.xz |
mm/memory-failure: move some function declarations into internal.h
There are some functions only used inside mm. Move them into internal.h.
No functional change intended.
Link: https://lkml.kernel.org/r/20240612071835.157004-11-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Reported-by: kernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202405251049.hxjwX7zO-lkp@intel.com/
Cc: Borislav Petkov (AMD) <bp@alien8.de>
Cc: David Hildenbrand <david@redhat.com>
Cc: Naoya Horiguchi <nao.horiguchi@gmail.com>
Cc: Tony Luck <tony.luck@intel.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm/internal.h')
-rw-r--r-- | mm/internal.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/mm/internal.h b/mm/internal.h index 0a190c3c55b0..b38eecaa48dd 100644 --- a/mm/internal.h +++ b/mm/internal.h @@ -1062,6 +1062,16 @@ extern u64 hwpoison_filter_flags_mask; extern u64 hwpoison_filter_flags_value; extern u64 hwpoison_filter_memcg; extern u32 hwpoison_filter_enable; +#define MAGIC_HWPOISON 0x48575053U /* HWPS */ +void SetPageHWPoisonTakenOff(struct page *page); +void ClearPageHWPoisonTakenOff(struct page *page); +bool take_page_off_buddy(struct page *page); +bool put_page_back_buddy(struct page *page); +struct task_struct *task_early_kill(struct task_struct *tsk, int force_early); +void add_to_kill_ksm(struct task_struct *tsk, struct page *p, + struct vm_area_struct *vma, struct list_head *to_kill, + unsigned long ksm_addr); +unsigned long page_mapped_in_vma(struct page *page, struct vm_area_struct *vma); extern unsigned long __must_check vm_mmap_pgoff(struct file *, unsigned long, unsigned long, unsigned long, |