The branch main has been updated by royger:

URL: 
https://cgit.FreeBSD.org/src/commit/?id=54a0b7203c30bfa5134ffc21f01c2e106f15e842

commit 54a0b7203c30bfa5134ffc21f01c2e106f15e842
Author:     Elliott Mitchell <ehem+free...@m5p.com>
AuthorDate: 2021-10-08 21:43:26 +0000
Commit:     Roger Pau Monné <roy...@freebsd.org>
CommitDate: 2023-11-28 12:22:30 +0000

    xen/apic: remove passing trapframe as argument
    
    While otherwise a handy potential approach, getting the trapframe via the
    argument isn't documented and isn't supposed to be used.  While
    ipi_bitmap_handler() and ipi_swi_handler() need to be passed the
    trapframe as their arguments, the Xen functions can retrieve it from
    curthread->td_intr_frame, which is the proper way.
    
    Reviewed by: royger
---
 sys/x86/xen/xen_apic.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/sys/x86/xen/xen_apic.c b/sys/x86/xen/xen_apic.c
index db2358bffa81..4f2b03879227 100644
--- a/sys/x86/xen/xen_apic.c
+++ b/sys/x86/xen/xen_apic.c
@@ -216,10 +216,8 @@ xen_pv_lapic_ipi_vectored(u_int vector, int dest)
 static int
 xen_ipi_bitmap_handler(void *arg)
 {
-       struct trapframe *frame;
 
-       frame = arg;
-       ipi_bitmap_handler(*frame);
+       ipi_bitmap_handler(*curthread->td_intr_frame);
        return (FILTER_HANDLED);
 }
 
@@ -297,9 +295,8 @@ xen_cpususpend_handler(void *arg)
 static int
 xen_ipi_swi_handler(void *arg)
 {
-       struct trapframe *frame = arg;
 
-       ipi_swi_handler(*frame);
+       ipi_swi_handler(*curthread->td_intr_frame);
        return (FILTER_HANDLED);
 }
 

Reply via email to