Date: Mon, 7 Apr 2003 20:21:49 -0700 (PDT) From: Peter Wemm <peter@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 28481 for review Message-ID: <200304080321.h383Lnep073897@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=28481 Change 28481 by peter@peter_daintree on 2003/04/07 20:21:17 Ugh. Now it gets ugly. Anyway, this has a better chance of not blowing up. Do not mess with %fs because we use the MSR version. Affected files ... .. //depot/projects/hammer/sys/x86_64/isa/icu_vector.s#6 edit .. //depot/projects/hammer/sys/x86_64/x86_64/exception.s#14 edit Differences ... ==== //depot/projects/hammer/sys/x86_64/isa/icu_vector.s#6 (text+ko) ==== @@ -49,15 +49,14 @@ mov %ax,%ds ; \ mov %ax,%es ; \ #XXX mov $KPSEL,%ax ; \ - mov %ax,%fs ; \ +#XXX mov %ax,%fs ; \ FAKE_MCOUNT((12+ACTUALLY_PUSHED)*4(%rsp)) ; \ call critical_enter ; \ movq PCPU(CURTHREAD),%rbx ; \ incl TD_INTR_NESTING_LEVEL(%rbx) ; \ - pushq intr_unit + (irq_num) * 4 ; \ + movq intr_unit + (irq_num) * 4, %rdi ; \ call *intr_handler + (irq_num) * 4 ; /* do the work ASAP */ \ enable_icus ; /* (re)enable ASAP (helps edge trigger?) */ \ - addq $8,%rsp ; \ incl cnt+V_INTR ; /* book-keeping can wait */ \ movq intr_countp + (irq_num) * 4,%rax ; \ incq (%rax) ; \ @@ -104,7 +103,7 @@ mov %ax,%ds ; \ mov %ax,%es ; \ #XXX mov $KPSEL,%ax ; \ - mov %ax,%fs ; \ +#XXX mov %ax,%fs ; \ maybe_extra_ipending ; \ movb imen + IRQ_BYTE(irq_num),%al ; \ orb $IRQ_BIT(irq_num),%al ; \ @@ -114,9 +113,8 @@ movq PCPU(CURTHREAD),%rbx ; \ incl TD_INTR_NESTING_LEVEL(%ebx) ; \ FAKE_MCOUNT(13*4(%rsp)) ; /* XXX late to avoid double count */ \ - pushq $irq_num; /* pass the IRQ */ \ + movq $irq_num, %rdi; /* pass the IRQ */ \ call sched_ithd ; \ - addq $8, %rsp ; /* discard the parameter */ \ decl TD_INTR_NESTING_LEVEL(%rbx) ; \ MEXITCOUNT ; \ /* We could usually avoid the following jmp by inlining some of */ \ ==== //depot/projects/hammer/sys/x86_64/x86_64/exception.s#14 (text+ko) ==== @@ -267,9 +267,8 @@ testl $TDF_ASTPENDING | TDF_NEEDRESCHED,TD_FLAGS(%rax) je doreti_exit sti - pushq %rsp /* pass a pointer to the trapframe */ + movq %rsp, %rdi /* pass a pointer to the trapframe */ call ast - addq $8,%rsp jmp doreti_ast /* @@ -284,7 +283,8 @@ .globl doreti_popl_fs doreti_popl_fs: - popq %fs +# popq %fs + addq $8, %rsp .globl doreti_popl_es doreti_popl_es: popq %es
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200304080321.h383Lnep073897>