x86_64: fix RBX clobber in nested IRQ case

In the code path for nested interrupts, we are not saving
RBX, yet the assembly code is using it as a storage location
for the ISR.

Use RAX. It is backed up in both the nested and non-nested
cases, and the ASM code is not currently using it at that
point.

Fixes: #29594

Signed-off-by: Andrew Boie <andrew.p.boie@intel.com>
This commit is contained in:
Andrew Boie 2020-10-27 16:07:21 -07:00 committed by Andrew Boie
parent 3332e15920
commit edc5e31d6b

View file

@ -707,9 +707,9 @@ irq_enter_unnested: /* Not nested: dump state to thread struct for __resume */
#endif #endif
irq_dispatch: irq_dispatch:
movq x86_irq_funcs(,%rcx,8), %rbx movq x86_irq_funcs(,%rcx,8), %rax
movq x86_irq_args(,%rcx,8), %rdi movq x86_irq_args(,%rcx,8), %rdi
call *%rbx call *%rax
xorq %rax, %rax xorq %rax, %rax
#ifdef CONFIG_X2APIC #ifdef CONFIG_X2APIC