Skip to content
This repository was archived by the owner on Nov 8, 2023. It is now read-only.

Commit dc189b8

Browse files
committed
Merge tag 'mm-hotfixes-stable-2024-03-27-11-25' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Pull misc fixes from Andrew Morton: "Various hotfixes. About half are cc:stable and the remainder address post-6.8 issues or aren't considered suitable for backporting. zswap figures prominently in the post-6.8 issues - folloup against the large amount of changes we have just made to that code. Apart from that, all over the map" * tag 'mm-hotfixes-stable-2024-03-27-11-25' of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm: (21 commits) crash: use macro to add crashk_res into iomem early for specific arch mm: zswap: fix data loss on SWP_SYNCHRONOUS_IO devices selftests/mm: fix ARM related issue with fork after pthread_create hexagon: vmlinux.lds.S: handle attributes section userfaultfd: fix deadlock warning when locking src and dst VMAs tmpfs: fix race on handling dquot rbtree selftests/mm: sigbus-wp test requires UFFD_FEATURE_WP_HUGETLBFS_SHMEM mm: zswap: fix writeback shinker GFP_NOIO/GFP_NOFS recursion ARM: prctl: reject PR_SET_MDWE on pre-ARMv6 prctl: generalize PR_SET_MDWE support check to be per-arch MAINTAINERS: remove incorrect M: tag for dm-devel@lists.linux.dev mm: zswap: fix kernel BUG in sg_init_one selftests: mm: restore settings from only parent process tools/Makefile: remove cgroup target mm: cachestat: fix two shmem bugs mm: increase folio batch size mm,page_owner: fix recursion mailmap: update entry for Leonard Crestez init: open /initrd.image with O_LARGEFILE selftests/mm: Fix build with _FORTIFY_SOURCE ...
2 parents 9624905 + 32fbe52 commit dc189b8

File tree

25 files changed

+177
-40
lines changed

25 files changed

+177
-40
lines changed

.mailmap

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,8 @@ Lee Jones <lee@kernel.org> <joneslee@google.com>
340340
Lee Jones <lee@kernel.org> <lee.jones@canonical.com>
341341
Lee Jones <lee@kernel.org> <lee.jones@linaro.org>
342342
Lee Jones <lee@kernel.org> <lee@ubuntu.com>
343-
Leonard Crestez <leonard.crestez@nxp.com> Leonard Crestez <cdleonard@gmail.com>
343+
Leonard Crestez <cdleonard@gmail.com> <leonard.crestez@nxp.com>
344+
Leonard Crestez <cdleonard@gmail.com> <leonard.crestez@intel.com>
344345
Leonardo Bras <leobras.c@gmail.com> <leonardo@linux.ibm.com>
345346
Leonard Göhrs <l.goehrs@pengutronix.de>
346347
Leonid I Ananiev <leonid.i.ananiev@intel.com>

MAINTAINERS

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6173,7 +6173,6 @@ F: include/uapi/linux/dm-*.h
61736173

61746174
DEVICE-MAPPER VDO TARGET
61756175
M: Matthew Sakai <msakai@redhat.com>
6176-
M: dm-devel@lists.linux.dev
61776176
L: dm-devel@lists.linux.dev
61786177
S: Maintained
61796178
F: Documentation/admin-guide/device-mapper/vdo*.rst

arch/arm/include/asm/mman.h

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/* SPDX-License-Identifier: GPL-2.0 */
2+
#ifndef __ASM_MMAN_H__
3+
#define __ASM_MMAN_H__
4+
5+
#include <asm/system_info.h>
6+
#include <uapi/asm/mman.h>
7+
8+
static inline bool arch_memory_deny_write_exec_supported(void)
9+
{
10+
return cpu_architecture() >= CPU_ARCH_ARMv6;
11+
}
12+
#define arch_memory_deny_write_exec_supported arch_memory_deny_write_exec_supported
13+
14+
#endif /* __ASM_MMAN_H__ */

arch/hexagon/kernel/vmlinux.lds.S

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ SECTIONS
6363
STABS_DEBUG
6464
DWARF_DEBUG
6565
ELF_DETAILS
66+
.hexagon.attributes 0 : { *(.hexagon.attributes) }
6667

6768
DISCARDS
6869
}

arch/parisc/include/asm/mman.h

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
/* SPDX-License-Identifier: GPL-2.0 */
2+
#ifndef __ASM_MMAN_H__
3+
#define __ASM_MMAN_H__
4+
5+
#include <uapi/asm/mman.h>
6+
7+
/* PARISC cannot allow mdwe as it needs writable stacks */
8+
static inline bool arch_memory_deny_write_exec_supported(void)
9+
{
10+
return false;
11+
}
12+
#define arch_memory_deny_write_exec_supported arch_memory_deny_write_exec_supported
13+
14+
#endif /* __ASM_MMAN_H__ */

arch/x86/include/asm/crash_reserve.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,6 @@ static inline unsigned long crash_low_size_default(void)
3939
#endif
4040
}
4141

42+
#define HAVE_ARCH_ADD_CRASH_RES_TO_IOMEM_EARLY
43+
4244
#endif /* _X86_CRASH_RESERVE_H */

include/linux/mman.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,14 @@ calc_vm_flag_bits(unsigned long flags)
162162

163163
unsigned long vm_commit_limit(void);
164164

165+
#ifndef arch_memory_deny_write_exec_supported
166+
static inline bool arch_memory_deny_write_exec_supported(void)
167+
{
168+
return true;
169+
}
170+
#define arch_memory_deny_write_exec_supported arch_memory_deny_write_exec_supported
171+
#endif
172+
165173
/*
166174
* Denies creating a writable executable mapping or gaining executable permissions.
167175
*

include/linux/pagevec.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111

1212
#include <linux/types.h>
1313

14-
/* 15 pointers + header align the folio_batch structure to a power of two */
15-
#define PAGEVEC_SIZE 15
14+
/* 31 pointers + header align the folio_batch structure to a power of two */
15+
#define PAGEVEC_SIZE 31
1616

1717
struct folio;
1818

init/initramfs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -682,7 +682,7 @@ static void __init populate_initrd_image(char *err)
682682

683683
printk(KERN_INFO "rootfs image is not initramfs (%s); looks like an initrd\n",
684684
err);
685-
file = filp_open("/initrd.image", O_WRONLY | O_CREAT, 0700);
685+
file = filp_open("/initrd.image", O_WRONLY|O_CREAT|O_LARGEFILE, 0700);
686686
if (IS_ERR(file))
687687
return;
688688

kernel/crash_reserve.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,7 +366,9 @@ static int __init reserve_crashkernel_low(unsigned long long low_size)
366366

367367
crashk_low_res.start = low_base;
368368
crashk_low_res.end = low_base + low_size - 1;
369+
#ifdef HAVE_ARCH_ADD_CRASH_RES_TO_IOMEM_EARLY
369370
insert_resource(&iomem_resource, &crashk_low_res);
371+
#endif
370372
#endif
371373
return 0;
372374
}
@@ -448,8 +450,12 @@ void __init reserve_crashkernel_generic(char *cmdline,
448450

449451
crashk_res.start = crash_base;
450452
crashk_res.end = crash_base + crash_size - 1;
453+
#ifdef HAVE_ARCH_ADD_CRASH_RES_TO_IOMEM_EARLY
454+
insert_resource(&iomem_resource, &crashk_res);
455+
#endif
451456
}
452457

458+
#ifndef HAVE_ARCH_ADD_CRASH_RES_TO_IOMEM_EARLY
453459
static __init int insert_crashkernel_resources(void)
454460
{
455461
if (crashk_res.start < crashk_res.end)
@@ -462,3 +468,4 @@ static __init int insert_crashkernel_resources(void)
462468
}
463469
early_initcall(insert_crashkernel_resources);
464470
#endif
471+
#endif

0 commit comments

Comments
 (0)