|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: Xen 4.22.1: CONFIG_LIVEPATCH=n with CONFIG_XSM=y crash
On 03/12/2026 8:05 pm, James Dingwall wrote: > Hi, > > I'm going through the process of updating our Xen build from 4.20.5 to 4.22.1. > I've maintained the .config from 4.20.5 which had CONFIG_LIVEPATCH=n and > CONFIG_XSM=y and just updated for the new release with `make -C xen > oldconfig`. > As soon as the dom0 memory is ballooned Xen crashes: > > (XEN) [2026-12-03 13:24:40.751] ----[ Xen-4.22.1 x86_64 debug=n Not > tainted ]---- > (XEN) [2026-12-03 13:24:40.751] CPU: 0 > (XEN) [2026-12-03 13:24:40.751] RIP: e008:[<ffff82d040235649>] > do_memory_op+0x829/0x2b5e > (XEN) [2026-12-03 13:24:40.751] RFLAGS: 0000000000010202 CONTEXT: > hypervisor (d0v0) > (XEN) [2026-12-03 13:24:40.751] rax: 0000000000000001 rbx: ffff831077c6ffff > rcx: 0000000000000001 > (XEN) [2026-12-03 13:24:40.751] rdx: 00000000ffffffff rsi: ffff831077c6fd78 > rdi: 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] rbp: 0000000000000000 rsp: ffff831077c6fbf0 > r8: 00000000000000ff > (XEN) [2026-12-03 13:24:40.751] r9: 0000000000000001 r10: 0000000000000000 > r11: 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] r12: ffff83104f8d5000 r13: ffffc90040457dd8 > r14: 0000000000000001 > (XEN) [2026-12-03 13:24:40.751] r15: 0000000000000000 cr0: 0000000080050033 > cr4: 00000000003526e0 > (XEN) [2026-12-03 13:24:40.751] cr3: 00000009d2423000 cr2: ffff82d040459b40 > (XEN) [2026-12-03 13:24:40.751] fsb: 0000000000000000 gsb: ffff889046c00000 > gss: 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] ds: 0000 es: 0000 fs: 0000 gs: 0000 > ss: e010 cs: e008 > (XEN) [2026-12-03 13:24:40.751] Xen code around <ffff82d040235649> > (do_memory_op+0x829/0x2b5e): > (XEN) [2026-12-03 13:24:40.751] 01 89 ac 24 8c 01 00 00 <48> 8b 15 f0 44 22 > 00 c7 84 24 90 01 00 00 00 00 > (XEN) [2026-12-03 13:24:40.751] Xen stack trace from rsp=ffff831077c6fbf0: > (XEN) [2026-12-03 13:24:40.751] ffff83104f8d5000 8086000000008086 > 0000000000000000 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] 0000000000000003 0000000000000000 > 0000000000000000 8086000000008086 > (XEN) [2026-12-03 13:24:40.751] 0000000000000000 0000000000000000 > 0000000000000000 0203001a00000000 > (XEN) [2026-12-03 13:24:40.751] 0e00000001480000 ffff82d0402507e4 > ffffffff83f508a0 0000000000000200 > (XEN) [2026-12-03 13:24:40.751] 0000000000000000 0000000000007ff0 > ffff83104f8ecdf0 ffff83104f8dc080 > (XEN) [2026-12-03 13:24:40.751] 0000000100000007 0000000000000000 > 0000000000000000 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] 0000000000000003 00000000000000c0 > 0000000000000000 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] 0000000000000000 ffff82d0405ff058 > ffff82d0405ff100 000000000000006f > (XEN) [2026-12-03 13:24:40.751] ffff83100000006f ffff82d040600118 > 0000000000000202 ffff82d0402567bd > (XEN) [2026-12-03 13:24:40.751] 0000000000000202 aaaaaaaaaaaaaaaa > ffff83104f8c1000 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] 0000000000000206 ffff82d040350cb3 > 0000000000000000 0000000000000003 > (XEN) [2026-12-03 13:24:40.751] 0000000000000003 0000000000000006 > ffff83104f8d5000 ffffffff83f508a0 > (XEN) [2026-12-03 13:24:40.751] 0000000000000200 0000000000000000 > ffff831077c6fd8c 00000cfb4f8afe20 > (XEN) [2026-12-03 13:24:40.751] ffffffff00000000 0000000000000001 > 0000000000000001 ffff83104f8d5000 > (XEN) [2026-12-03 13:24:40.751] ffff83104f8c7000 0000000000000206 > 0000000000000000 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] 0000000000000001 ffff83104f8d5000 > ffff83104f8c7000 ffff889046c1fad0 > (XEN) [2026-12-03 13:24:40.751] 0000000000000000 ffff83104f8d5000 > ffff82d040347b25 0000000000000000 > (XEN) [2026-12-03 13:24:40.751] ffff831077c6fe48 0000000100007ff0 > ffff82d04021ffcc ffff830043fbc070 > (XEN) [2026-12-03 13:24:40.751] ffff82e000000000 0000000000000000 > ffff888100000000 0000000000000006 > (XEN) [2026-12-03 13:24:40.751] 00000000009d2423 0000000000000000 > ffff831077c6ff08 000000000000000c > (XEN) [2026-12-03 13:24:40.751] Xen call trace: > (XEN) [2026-12-03 13:24:40.751] [<ffff82d040235649>] R > do_memory_op+0x829/0x2b5e > (XEN) [2026-12-03 13:24:40.751] [<ffff82d0402507e4>] S > common/sched/credit2.c#runq_tickle+0x304/0x651 > (XEN) [2026-12-03 13:24:40.751] [<ffff82d0402567bd>] S > vcpu_wake+0x13d/0x224 > (XEN) [2026-12-03 13:24:40.751] [<ffff82d040350cb3>] S > send_IPI_mask+0xc3/0x20b > (XEN) [2026-12-03 13:24:40.751] [<ffff82d040347b25>] S > do_mmuext_op+0xda5/0x14eb > (XEN) [2026-12-03 13:24:40.751] [<ffff82d04021ffcc>] S > do_event_channel_op+0x1cc/0x112a > (XEN) [2026-12-03 13:24:40.751] [<ffff82d04031d0fa>] S > pv_hypercall+0x50a/0x563 > (XEN) [2026-12-03 13:24:40.751] [<ffff82d04020142d>] S > lstar_enter+0x13d/0x142 > (XEN) [2026-12-03 13:24:40.751] > (XEN) [2026-12-03 13:24:40.751] Pagetable walk from ffff82d040459b40: > (XEN) [2026-12-03 13:24:40.751] L4[0x105] = 000000006fcb1063 ffffffffffffffff > (XEN) [2026-12-03 13:24:40.751] L3[0x141] = 000000006fcae063 ffffffffffffffff > (XEN) [2026-12-03 13:24:40.751] L2[0x002] = 0000001077c79063 ffffffffffffffff > (XEN) [2026-12-03 13:24:40.751] L1[0x059] = 0000000000000000 ffffffffffffffff > (XEN) [2026-12-03 13:24:41.162] > (XEN) [2026-12-03 13:24:41.165] **************************************** > (XEN) [2026-12-03 13:24:41.172] Panic on CPU 0: > (XEN) [2026-12-03 13:24:41.176] FATAL PAGE FAULT > (XEN) [2026-12-03 13:24:41.180] [error_code=0000] > (XEN) [2026-12-03 13:24:41.185] Faulting linear address: ffff82d040459b40 > (XEN) [2026-12-03 13:24:41.191] **************************************** > (XEN) [2026-12-03 13:24:41.198] > (XEN) [2026-12-03 13:24:41.201] Reboot in five seconds... > (XEN) [2026-12-03 13:24:46.206] Resetting with ACPI MEMORY or I/O RESET_REG. > > Google AI suggested that the xsm_ops structure was being freed and that > toggling the LIVEPATCH .config option would prevent the crash, which it does. > I don't know if this dependency between the config options needs to be > expressed to avoid an invalid .config combination or whether a different > change is needed to allow XSM to remain independent of LIVEPATCH. > > Trying to summarise the complete exchange if LIVEPATCH=n then xsm_ops is > in .init.data and gets unmapped after boot. With LIVEPATCH=y xsm_ops is > in .data.ro_after_init. These are details that don't mean much to me so > it is possible I have misunderstood. > > I am building a patched tree but I don't believe there are changes which > would cause this. Hmm. We should have de-virtualised all XSM function pointers by this point, and shouldn't have any remaining references to the xsm_ops structure. This is both a speculative execution hardening, and performance improvement. Can you run addr2line and identify ffff82d040235649 more precisely? Can you provide the full .config before and after, and the full xl dmesg please? Thanks, ~Andrew
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |