History

Merge tag 'mm-hotfixes-stable-2026-01-29-09-41' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

Pull misc fixes from Andrew Morton: "16 hotfixes. 9 are cc:stable, 12 are for MM. There's a patch series from Pratyush Yadav which fixes a few things in the new-in-6.19 LUO memfd code. Plus the usual shower of singletons - please see the changelogs for details" * tag 'mm-hotfixes-stable-2026-01-29-09-41' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm: vmcoreinfo: make hwerr_data visible for debugging mm/zone_device: reinitialize large zone device private folios mm/mm_init: don't cond_resched() in deferred_init_memmap_chunk() if called from deferred_grow_zone() mm/kfence: randomize the freelist on initialization kho: kho_preserve_vmalloc(): don't return 0 when ENOMEM kho: init alloc tags when restoring pages from reserved memory mm: memfd_luo: restore and free memfd_luo_ser on failure mm: memfd_luo: use memfd_alloc_file() instead of shmem_file_setup() memfd: export alloc_file() flex_proportions: make fprop_new_period() hardirq safe mailmap: add entry for Viacheslav Bocharov mm/memory-failure: teach kill_accessing_process to accept hugetlb tail page pfn mm/memory-failure: fix missing ->mf_stats count in hugetlb poison mm, swap: restore swap_space attr aviod kernel panic mm/kasan: fix KASAN poisoning in vrealloc() mm/shmem, swap: fix race of truncate and swap entry split

Linus Torvalds committed 9 months ago

Commit bcb60582 parents 1cac389 bd5878223 files · +239 −87Browse files

Showing the changes to include/linux (3 of 23 files). Show all

Unified · Split

3 files
  1. include/linux/kasan.h +14 −0
  2. include/linux/memfd.h +6 −0
  3. include/linux/memremap.h +6 −3
include/linux/kasan.h+14−0
@@ -641,6 +641,17 @@ kasan_unpoison_vmap_areas(struct vm_struct **vms, int nr_vms, · 640 unmodified lines
641 __kasan_unpoison_vmap_areas(vms, nr_vms, flags);641 __kasan_unpoison_vmap_areas(vms, nr_vms, flags);
642}642}
643 643
644void __kasan_vrealloc(const void *start, unsigned long old_size,
645 unsigned long new_size);
646
647static __always_inline void kasan_vrealloc(const void *start,
648 unsigned long old_size,
649 unsigned long new_size)
650{
651 if (kasan_enabled())
652 __kasan_vrealloc(start, old_size, new_size);
653}
654
644#else /* CONFIG_KASAN_VMALLOC */655#else /* CONFIG_KASAN_VMALLOC */
645 656
646static inline void kasan_populate_early_vm_area_shadow(void *start,657static inline void kasan_populate_early_vm_area_shadow(void *start,
@@ -670,6 +681,9 @@ kasan_unpoison_vmap_areas(struct vm_struct **vms, int nr_vms, · 23 unmodified lines
670 kasan_vmalloc_flags_t flags)681 kasan_vmalloc_flags_t flags)
671{ }682{ }
672 683
684static inline void kasan_vrealloc(const void *start, unsigned long old_size,
685 unsigned long new_size) { }
686
673#endif /* CONFIG_KASAN_VMALLOC */687#endif /* CONFIG_KASAN_VMALLOC */
674 688
675#if (defined(CONFIG_KASAN_GENERIC) || defined(CONFIG_KASAN_SW_TAGS)) && \689#if (defined(CONFIG_KASAN_GENERIC) || defined(CONFIG_KASAN_SW_TAGS)) && \
include/linux/memfd.h+6−0
@@ -17,6 +17,7 @@ struct folio *memfd_alloc_folio(struct file *memfd, pgoff_t idx); · 16 unmodified lines
17 * to by vm_flags_ptr.17 * to by vm_flags_ptr.
18 */18 */
19int memfd_check_seals_mmap(struct file *file, vm_flags_t *vm_flags_ptr);19int memfd_check_seals_mmap(struct file *file, vm_flags_t *vm_flags_ptr);
20struct file *memfd_alloc_file(const char *name, unsigned int flags);
20#else21#else
21static inline long memfd_fcntl(struct file *f, unsigned int c, unsigned int a)22static inline long memfd_fcntl(struct file *f, unsigned int c, unsigned int a)
22{23{
@@ -31,6 +32,11 @@ static inline int memfd_check_seals_mmap(struct file *file, · 8 unmodified lines
31{32{
32 return 0;33 return 0;
33}34}
35
36static inline struct file *memfd_alloc_file(const char *name, unsigned int flags)
37{
38 return ERR_PTR(-EINVAL);
39}
34#endif40#endif
35 41
36#endif /* __LINUX_MEMFD_H */42#endif /* __LINUX_MEMFD_H */
include/linux/memremap.h+6−3
@@ -224,7 +224,8 @@ static inline bool is_fsdax_page(const struct page *page) · 223 unmodified lines
224}224}
225 225
226#ifdef CONFIG_ZONE_DEVICE226#ifdef CONFIG_ZONE_DEVICE
227void zone_device_page_init(struct page *page, unsigned int order);227void zone_device_page_init(struct page *page, struct dev_pagemap *pgmap,
228 unsigned int order);
228void *memremap_pages(struct dev_pagemap *pgmap, int nid);229void *memremap_pages(struct dev_pagemap *pgmap, int nid);
229void memunmap_pages(struct dev_pagemap *pgmap);230void memunmap_pages(struct dev_pagemap *pgmap);
230void *devm_memremap_pages(struct device *dev, struct dev_pagemap *pgmap);231void *devm_memremap_pages(struct device *dev, struct dev_pagemap *pgmap);
@@ -234,9 +235,11 @@ bool pgmap_pfn_valid(struct dev_pagemap *pgmap, unsigned long pfn); · 3 unmodified lines
234 235
235unsigned long memremap_compat_align(void);236unsigned long memremap_compat_align(void);
236 237
237static inline void zone_device_folio_init(struct folio *folio, unsigned int order)238static inline void zone_device_folio_init(struct folio *folio,
239 struct dev_pagemap *pgmap,
240 unsigned int order)
238{241{
239 zone_device_page_init(&folio->page, order);242 zone_device_page_init(&folio->page, pgmap, order);
240 if (order)243 if (order)
241 folio_set_large_rmappable(folio);244 folio_set_large_rmappable(folio);
242}245}