Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux

Pull arm64 fixes from Catalin Marinas:

- Correctly mask out bits 63:60 in a kernel tag check fault address
(specified as unknown by the architecture). Previously they were just
zeroed but for kernel pointers they need to be all ones.

- Fix a panic (unexpected kernel BRK exception) caused by kprobes being
reentered due to an interrupt.

* tag 'arm64-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux:
arm64: kprobes: Fix Uexpected kernel BRK exception at EL1
kasan, arm64: fix pointer tags in KASAN reports

+6 -5
+2 -2
arch/arm64/kernel/probes/kprobes.c
··· 352 352 unsigned long addr = instruction_pointer(regs); 353 353 struct kprobe *cur = kprobe_running(); 354 354 355 - if (cur && (kcb->kprobe_status == KPROBE_HIT_SS) 356 - && ((unsigned long)&cur->ainsn.api.insn[1] == addr)) { 355 + if (cur && (kcb->kprobe_status & (KPROBE_HIT_SS | KPROBE_REENTER)) && 356 + ((unsigned long)&cur->ainsn.api.insn[1] == addr)) { 357 357 kprobes_restore_local_irqflag(kcb, regs); 358 358 post_kprobe_handler(cur, kcb, regs); 359 359
+4 -3
arch/arm64/mm/fault.c
··· 709 709 struct pt_regs *regs) 710 710 { 711 711 /* 712 - * The architecture specifies that bits 63:60 of FAR_EL1 are UNKNOWN for tag 713 - * check faults. Mask them out now so that userspace doesn't see them. 712 + * The architecture specifies that bits 63:60 of FAR_EL1 are UNKNOWN 713 + * for tag check faults. Set them to corresponding bits in the untagged 714 + * address. 714 715 */ 715 - far &= (1UL << 60) - 1; 716 + far = (__untagged_addr(far) & ~MTE_TAG_MASK) | (far & MTE_TAG_MASK); 716 717 do_bad_area(far, esr, regs); 717 718 return 0; 718 719 }