diff options
author | jake <jake@FreeBSD.org> | 2000-12-13 09:23:53 +0000 |
---|---|---|
committer | jake <jake@FreeBSD.org> | 2000-12-13 09:23:53 +0000 |
commit | 90d90d0c248fbcde27a7d443098c2bf514aaa199 (patch) | |
tree | 48852dbfa3490f6dfe3145145122f26ee2991cd5 /sys/i386/isa/ipl.s | |
parent | 46b93fb7883b21c43eeac8eb6f58b1288edb2518 (diff) | |
download | FreeBSD-src-90d90d0c248fbcde27a7d443098c2bf514aaa199.zip FreeBSD-src-90d90d0c248fbcde27a7d443098c2bf514aaa199.tar.gz |
Introduce a new potientially cleaner interface for accessing per-cpu
variables from i386 assembly language. The syntax is PCPU(member)
where member is the capitalized name of the per-cpu variable, without
the gd_ prefix. Example: movl %eax,PCPU(CURPROC). The capitalization
is due to using the offsets generated by genassym rather than the symbols
provided by linking with globals.o. asmacros.h is the wrong place for
this but it seemed as good a place as any for now. The old implementation
in asnames.h has not been removed because it is still used to de-mangle
the symbols used by the C variables for the UP case.
Diffstat (limited to 'sys/i386/isa/ipl.s')
-rw-r--r-- | sys/i386/isa/ipl.s | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/i386/isa/ipl.s b/sys/i386/isa/ipl.s index a079d2c..3f8fc96 100644 --- a/sys/i386/isa/ipl.s +++ b/sys/i386/isa/ipl.s @@ -80,10 +80,10 @@ _softtty_imask: .long 0 _doreti: FAKE_MCOUNT(_bintr) /* init "from" _bintr -> _doreti */ doreti_next: - decb _intr_nesting_level + decb PCPU(INTR_NESTING_LEVEL) /* Check for ASTs that can be handled now. */ - testl $AST_PENDING,_astpending + testl $AST_PENDING,PCPU(ASTPENDING) je doreti_exit /* no AST, exit */ testb $SEL_RPL_MASK,TF_CS(%esp) /* are we in user mode? */ jne doreti_ast /* yes, do it now. */ @@ -147,11 +147,11 @@ doreti_popl_fs_fault: ALIGN_TEXT doreti_ast: - andl $~AST_PENDING,_astpending + andl $~AST_PENDING,PCPU(ASTPENDING) sti movl $T_ASTFLT,TF_TRAPNO(%esp) call _ast - movb $1,_intr_nesting_level /* for doreti_next to decrement */ + movb $1,PCPU(INTR_NESTING_LEVEL) /* for doreti_next to decrement */ jmp doreti_next #ifdef APIC_IO |