Skip to content

Commit 4b24d25

Browse files
committed
Merge tag 'v6.18.10' into 6.18-main
This is the 6.18.10 stable release # -----BEGIN PGP SIGNATURE----- # # iQIzBAABCgAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAmmMeSAACgkQONu9yGCS # aT6H2RAAnGR2Zh8ZBFfYTS9u6HRAOJUK4RBEU8mkEP1BDXnCUJlRhFcoVD0NTTKp # C/T9WL9q3Sp0o3gXGwnHtBi1MDWcVi39ktMh1jWrqMG9x7BaAufyXkbIA5vqccKD # AyI4CD9H7sFVPYuvmPVI9P3GR4Zgq3QdHG1EQR//pQYaBDMIlVGx1/+aG3CrZ5fJ # 2VI0V42Pkj5O9B084/Zxcc2F8MLYkeZ+R4jr0RVe+aeS0j+jnlgbimhL/qMvqe5D # ch6oucLVulbIlztXQqCtn0iQajEIu7tH5AUfCvZQa+FzT1j4H+SlbB2G25bUO6VI # lQiw6KnxENFpDtKSFnPtPmDsq+vP3pFBnJ3LMjPdroAnPBRMWY9WpEiQfO90BgU1 # hYFesF7rOhbrYCw3bf5Tl51Az48Lwm3Z7/L3CO2ROEy06ly4Ynw5ZdTEnvqPPhd6 # C2vu40b+33DOIZ+NaBZlxm0F/OKVPLXYQ+EAbPOApn2akOBduD8KMbOg6RcBRptK # dBzxOKwaqoRMjb8ZMXjvp6INbaW9iL2RPi8P64bH+NIlh5t5L8tb3fdgobewFJJb # 1kDzXpmhbZ+nxgJ5PDZeHjKmoyYeCo0eATQ4sX+pGdaadZPyCVCl3mpqj/nf/2AZ # Hdd0NlLFIRp4X5MKfbX9Rrs5YR1l7O8BY4WE9ZBJRcyBVupNa70= # =cJdj # -----END PGP SIGNATURE----- # gpg: Signature made Wed Feb 11 13:42:08 2026 CET # gpg: using RSA key 647F28654894E3BD457199BE38DBBDC86092693E # gpg: Can't check signature: No public key
2 parents 11c9760 + 41cec61 commit 4b24d25

265 files changed

Lines changed: 1871 additions & 1032 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: GPL-2.0
22
VERSION = 6
33
PATCHLEVEL = 18
4-
SUBLEVEL = 9
4+
SUBLEVEL = 10
55
EXTRAVERSION =
66
NAME = Baby Opossum Posse
77

arch/arm/include/asm/string.h

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,10 @@ static inline void *memset32(uint32_t *p, uint32_t v, __kernel_size_t n)
4242
extern void *__memset64(uint64_t *, uint32_t low, __kernel_size_t, uint32_t hi);
4343
static inline void *memset64(uint64_t *p, uint64_t v, __kernel_size_t n)
4444
{
45-
return __memset64(p, v, n * 8, v >> 32);
45+
if (IS_ENABLED(CONFIG_CPU_LITTLE_ENDIAN))
46+
return __memset64(p, v, n * 8, v >> 32);
47+
else
48+
return __memset64(p, v >> 32, n * 8, v);
4649
}
4750

4851
/*

arch/loongarch/kernel/traps.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -535,10 +535,15 @@ asmlinkage void noinstr do_fpe(struct pt_regs *regs, unsigned long fcsr)
535535
asmlinkage void noinstr do_ade(struct pt_regs *regs)
536536
{
537537
irqentry_state_t state = irqentry_enter(regs);
538+
unsigned int esubcode = FIELD_GET(CSR_ESTAT_ESUBCODE, regs->csr_estat);
539+
540+
if ((esubcode == EXSUBCODE_ADEM) && fixup_exception(regs))
541+
goto out;
538542

539543
die_if_kernel("Kernel ade access", regs);
540544
force_sig_fault(SIGBUS, BUS_ADRERR, (void __user *)regs->csr_badvaddr);
541545

546+
out:
542547
irqentry_exit(regs, state);
543548
}
544549

arch/loongarch/mm/cache.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,8 +160,8 @@ void cpu_cache_init(void)
160160

161161
static const pgprot_t protection_map[16] = {
162162
[VM_NONE] = __pgprot(_CACHE_CC | _PAGE_USER |
163-
_PAGE_PROTNONE | _PAGE_NO_EXEC |
164-
_PAGE_NO_READ),
163+
_PAGE_NO_EXEC | _PAGE_NO_READ |
164+
(_PAGE_PROTNONE ? : _PAGE_PRESENT)),
165165
[VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
166166
_PAGE_USER | _PAGE_PRESENT |
167167
_PAGE_NO_EXEC),
@@ -180,8 +180,8 @@ static const pgprot_t protection_map[16] = {
180180
[VM_EXEC | VM_WRITE | VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
181181
_PAGE_USER | _PAGE_PRESENT),
182182
[VM_SHARED] = __pgprot(_CACHE_CC | _PAGE_USER |
183-
_PAGE_PROTNONE | _PAGE_NO_EXEC |
184-
_PAGE_NO_READ),
183+
_PAGE_NO_EXEC | _PAGE_NO_READ |
184+
(_PAGE_PROTNONE ? : _PAGE_PRESENT)),
185185
[VM_SHARED | VM_READ] = __pgprot(_CACHE_CC | _PAGE_VALID |
186186
_PAGE_USER | _PAGE_PRESENT |
187187
_PAGE_NO_EXEC),

arch/riscv/include/asm/uaccess.h

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,13 +97,23 @@ static inline unsigned long __untagged_addr_remote(struct mm_struct *mm, unsigne
9797
*/
9898

9999
#ifdef CONFIG_CC_HAS_ASM_GOTO_OUTPUT
100+
/*
101+
* Use a temporary variable for the output of the asm goto to avoid a
102+
* triggering an LLVM assertion due to sign extending the output when
103+
* it is used in later function calls:
104+
* https://github.com/llvm/llvm-project/issues/143795
105+
*/
100106
#define __get_user_asm(insn, x, ptr, label) \
107+
do { \
108+
u64 __tmp; \
101109
asm_goto_output( \
102110
"1:\n" \
103111
" " insn " %0, %1\n" \
104112
_ASM_EXTABLE_UACCESS_ERR(1b, %l2, %0) \
105-
: "=&r" (x) \
106-
: "m" (*(ptr)) : : label)
113+
: "=&r" (__tmp) \
114+
: "m" (*(ptr)) : : label); \
115+
(x) = (__typeof__(x))(unsigned long)__tmp; \
116+
} while (0)
107117
#else /* !CONFIG_CC_HAS_ASM_GOTO_OUTPUT */
108118
#define __get_user_asm(insn, x, ptr, label) \
109119
do { \

arch/riscv/kernel/Makefile

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,6 @@
33
# Makefile for the RISC-V Linux kernel
44
#
55

6-
ifdef CONFIG_FTRACE
7-
CFLAGS_REMOVE_ftrace.o = $(CC_FLAGS_FTRACE)
8-
CFLAGS_REMOVE_patch.o = $(CC_FLAGS_FTRACE)
9-
CFLAGS_REMOVE_sbi.o = $(CC_FLAGS_FTRACE)
10-
CFLAGS_REMOVE_return_address.o = $(CC_FLAGS_FTRACE)
11-
endif
126
CFLAGS_syscall_table.o += $(call cc-disable-warning, override-init)
137
CFLAGS_compat_syscall_table.o += $(call cc-disable-warning, override-init)
148

@@ -24,7 +18,6 @@ CFLAGS_sbi_ecall.o := -mcmodel=medany
2418
ifdef CONFIG_FTRACE
2519
CFLAGS_REMOVE_alternative.o = $(CC_FLAGS_FTRACE)
2620
CFLAGS_REMOVE_cpufeature.o = $(CC_FLAGS_FTRACE)
27-
CFLAGS_REMOVE_sbi_ecall.o = $(CC_FLAGS_FTRACE)
2821
endif
2922
ifdef CONFIG_RELOCATABLE
3023
CFLAGS_alternative.o += -fno-pie
@@ -43,6 +36,14 @@ CFLAGS_sbi_ecall.o += -D__NO_FORTIFY
4336
endif
4437
endif
4538

39+
ifdef CONFIG_FTRACE
40+
CFLAGS_REMOVE_ftrace.o = $(CC_FLAGS_FTRACE)
41+
CFLAGS_REMOVE_patch.o = $(CC_FLAGS_FTRACE)
42+
CFLAGS_REMOVE_sbi.o = $(CC_FLAGS_FTRACE)
43+
CFLAGS_REMOVE_return_address.o = $(CC_FLAGS_FTRACE)
44+
CFLAGS_REMOVE_sbi_ecall.o = $(CC_FLAGS_FTRACE)
45+
endif
46+
4647
always-$(KBUILD_BUILTIN) += vmlinux.lds
4748

4849
obj-y += head.o

arch/riscv/kernel/traps.c

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,8 +339,10 @@ void do_trap_ecall_u(struct pt_regs *regs)
339339

340340
add_random_kstack_offset();
341341

342-
if (syscall >= 0 && syscall < NR_syscalls)
342+
if (syscall >= 0 && syscall < NR_syscalls) {
343+
syscall = array_index_nospec(syscall, NR_syscalls);
343344
syscall_handler(regs, syscall);
345+
}
344346

345347
/*
346348
* Ultimately, this value will get limited by KSTACK_OFFSET_MAX(),

arch/x86/coco/sev/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ UBSAN_SANITIZE_noinstr.o := n
88
# GCC may fail to respect __no_sanitize_address or __no_kcsan when inlining
99
KASAN_SANITIZE_noinstr.o := n
1010
KCSAN_SANITIZE_noinstr.o := n
11+
12+
GCOV_PROFILE_noinstr.o := n

arch/x86/include/asm/kfence.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ static inline bool kfence_protect_page(unsigned long addr, bool protect)
4242
{
4343
unsigned int level;
4444
pte_t *pte = lookup_address(addr, &level);
45-
pteval_t val;
45+
pteval_t val, new;
4646

4747
if (WARN_ON(!pte || level != PG_LEVEL_4K))
4848
return false;
@@ -57,11 +57,12 @@ static inline bool kfence_protect_page(unsigned long addr, bool protect)
5757
return true;
5858

5959
/*
60-
* Otherwise, invert the entire PTE. This avoids writing out an
60+
* Otherwise, flip the Present bit, taking care to avoid writing an
6161
* L1TF-vulnerable PTE (not present, without the high address bits
6262
* set).
6363
*/
64-
set_pte(pte, __pte(~val));
64+
new = val ^ _PAGE_PRESENT;
65+
set_pte(pte, __pte(flip_protnone_guard(val, new, PTE_PFN_MASK)));
6566

6667
/*
6768
* If the page was protected (non-present) and we're making it

arch/x86/include/asm/vmware.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ unsigned long vmware_hypercall3(unsigned long cmd, unsigned long in1,
140140
"b" (in1),
141141
"c" (cmd),
142142
"d" (0)
143-
: "cc", "memory");
143+
: "di", "si", "cc", "memory");
144144
return out0;
145145
}
146146

@@ -165,7 +165,7 @@ unsigned long vmware_hypercall4(unsigned long cmd, unsigned long in1,
165165
"b" (in1),
166166
"c" (cmd),
167167
"d" (0)
168-
: "cc", "memory");
168+
: "di", "si", "cc", "memory");
169169
return out0;
170170
}
171171

0 commit comments

Comments
 (0)