diff options
author | jkim <jkim@FreeBSD.org> | 2007-03-30 19:33:53 +0000 |
---|---|---|
committer | jkim <jkim@FreeBSD.org> | 2007-03-30 19:33:53 +0000 |
commit | d64527e9e12e384f5bd055d0af2ba9c42f7e43ee (patch) | |
tree | 4eb02cc3801cf5d953fccc59119b9bd94e660a7d /sys | |
parent | 87009ffe7dd781d2c670eb88e0f259436944574f (diff) | |
download | FreeBSD-src-d64527e9e12e384f5bd055d0af2ba9c42f7e43ee.zip FreeBSD-src-d64527e9e12e384f5bd055d0af2ba9c42f7e43ee.tar.gz |
Fix more style(9) nits[1] and remove unnecessary use of '#if !defined(_KERNEL)'.
Pointed out by: bde[1]
Diffstat (limited to 'sys')
-rw-r--r-- | sys/amd64/amd64/support.S | 72 | ||||
-rw-r--r-- | sys/i386/i386/support.s | 78 |
2 files changed, 75 insertions, 75 deletions
diff --git a/sys/amd64/amd64/support.S b/sys/amd64/amd64/support.S index d6b5f3d..2182d26 100644 --- a/sys/amd64/amd64/support.S +++ b/sys/amd64/amd64/support.S @@ -242,7 +242,7 @@ ENTRY(copyout) cmpq %rcx,%rax ja copyout_fault - xchgq %rdi, %rsi + xchgq %rdi,%rsi /* bcopy(%rsi, %rdi, %rdx) */ movq %rdx,%rcx @@ -288,8 +288,8 @@ ENTRY(copyin) cmpq %rcx,%rax ja copyin_fault - xchgq %rdi, %rsi - movq %rdx, %rcx + xchgq %rdi,%rsi + movq %rdx,%rcx movb %cl,%al shrq $3,%rcx /* copy longword-wise */ cld @@ -353,11 +353,11 @@ ENTRY(casuword) cmpq %rax,%rdi /* verify address is valid */ ja fusufault - movq %rsi, %rax /* old */ + movq %rsi,%rax /* old */ #ifdef SMP lock #endif - cmpxchgq %rdx, (%rdi) /* new = %rdx */ + cmpxchgq %rdx,(%rdi) /* new = %rdx */ /* * The old value is in %eax. If the store succeeded it will be the @@ -501,7 +501,7 @@ ENTRY(subyte) cmpq %rax,%rdi /* verify address validity */ ja fusufault - movl %esi, %eax + movl %esi,%eax movb %al,(%rdi) xorl %eax,%eax movq PCPU(CURPCB),%rcx /* restore trashed register */ @@ -518,9 +518,9 @@ ENTRY(subyte) * return the actual length in *lencopied. */ ENTRY(copyinstr) - movq %rdx, %r8 /* %r8 = maxlen */ - movq %rcx, %r9 /* %r9 = *len */ - xchgq %rdi, %rsi /* %rdi = from, %rsi = to */ + movq %rdx,%r8 /* %r8 = maxlen */ + movq %rcx,%r9 /* %r9 = *len */ + xchgq %rdi,%rsi /* %rdi = from, %rsi = to */ movq PCPU(CURPCB),%rcx movq $cpystrflt,PCB_ONFAULT(%rcx) @@ -582,9 +582,9 @@ cpystrflt_x: * %rdi, %rsi, %rdx, %rcx */ ENTRY(copystr) - movq %rdx, %r8 /* %r8 = maxlen */ + movq %rdx,%r8 /* %r8 = maxlen */ - xchgq %rdi, %rsi + xchgq %rdi,%rsi incq %rdx cld 1: @@ -605,11 +605,11 @@ ENTRY(copystr) 6: - testq %rcx, %rcx + testq %rcx,%rcx jz 7f /* set *lencopied and return %rax */ - subq %rdx, %r8 - movq %r8, (%rcx) + subq %rdx,%r8 + movq %r8,(%rcx) 7: ret @@ -626,7 +626,7 @@ ENTRY(lgdt) jmp 1f nop 1: - movl $KDSEL, %eax + movl $KDSEL,%eax movl %eax,%ds movl %eax,%es movl %eax,%fs /* Beware, use wrmsr to set 64 bit base */ @@ -693,43 +693,43 @@ NON_GPROF_ENTRY(__bb_init_func) .text futex_fault: - movq PCPU(CURPCB), %rdx - movq $0, PCB_ONFAULT(%rdx) - movq $-EFAULT, %rax + movq PCPU(CURPCB),%rdx + movq $0,PCB_ONFAULT(%rdx) + movq $-EFAULT,%rax ret /* int futex_xchgl(int oparg, caddr_t uaddr, int *oldval); */ ENTRY(futex_xchgl) - movq PCPU(CURPCB), %r11 - movq $futex_fault, PCB_ONFAULT(%r11) + movq PCPU(CURPCB),%r11 + movq $futex_fault,PCB_ONFAULT(%r11) - movq $VM_MAXUSER_ADDRESS-4, %rax - cmpq %rax, %rsi + movq $VM_MAXUSER_ADDRESS-4,%rax + cmpq %rax,%rsi ja futex_fault -#if defined(SMP) || !defined(_KERNEL) +#ifdef SMP lock #endif - xchgl %edi, (%rsi) - movl %edi, (%rdx) - xorl %eax, %eax - movq %rax, PCB_ONFAULT(%r11) + xchgl %edi,(%rsi) + movl %edi,(%rdx) + xorl %eax,%eax + movq %rax,PCB_ONFAULT(%r11) ret /* int futex_addl(int oparg, caddr_t uaddr, int *oldval); */ ENTRY(futex_addl) - movq PCPU(CURPCB), %r11 - movq $futex_fault, PCB_ONFAULT(%r11) + movq PCPU(CURPCB),%r11 + movq $futex_fault,PCB_ONFAULT(%r11) - movq $VM_MAXUSER_ADDRESS-4, %rax - cmpq %rax, %rsi + movq $VM_MAXUSER_ADDRESS-4,%rax + cmpq %rax,%rsi ja futex_fault -#if defined(SMP) || !defined(_KERNEL) +#ifdef SMP lock #endif - xaddl %edi, (%rsi) - movl %edi, (%rdx) - xorl %eax, %eax - movq %rax, PCB_ONFAULT(%r11) + xaddl %edi,(%rsi) + movl %edi,(%rdx) + xorl %eax,%eax + movq %rax,PCB_ONFAULT(%r11) ret diff --git a/sys/i386/i386/support.s b/sys/i386/i386/support.s index 9b2f5f0..645a80f 100644 --- a/sys/i386/i386/support.s +++ b/sys/i386/i386/support.s @@ -376,13 +376,13 @@ ENTRY(i686_pagezero) pushl %edi pushl %ebx - movl 12(%esp), %edi - movl $1024, %ecx + movl 12(%esp),%edi + movl $1024,%ecx cld ALIGN_TEXT 1: - xorl %eax, %eax + xorl %eax,%eax repe scasl jnz 2f @@ -395,27 +395,27 @@ ENTRY(i686_pagezero) 2: incl %ecx - subl $4, %edi + subl $4,%edi - movl %ecx, %edx - cmpl $16, %ecx + movl %ecx,%edx + cmpl $16,%ecx jge 3f - movl %edi, %ebx - andl $0x3f, %ebx + movl %edi,%ebx + andl $0x3f,%ebx shrl %ebx shrl %ebx - movl $16, %ecx - subl %ebx, %ecx + movl $16,%ecx + subl %ebx,%ecx 3: - subl %ecx, %edx + subl %ecx,%edx rep stosl - movl %edx, %ecx - testl %edx, %edx + movl %edx,%ecx + testl %edx,%edx jnz 1b popl %ebx @@ -1157,7 +1157,7 @@ ENTRY(casuword) #ifdef SMP lock #endif - cmpxchgl %ecx, (%edx) /* Compare and set. */ + cmpxchgl %ecx,(%edx) /* Compare and set. */ /* * The old value is in %eax. If the store succeeded it will be the @@ -1537,49 +1537,49 @@ NON_GPROF_ENTRY(__bb_init_func) .text futex_fault: - movl PCPU(CURPCB), %edx - movl $0, PCB_ONFAULT(%edx) - movl $-EFAULT, %eax + movl PCPU(CURPCB),%edx + movl $0,PCB_ONFAULT(%edx) + movl $-EFAULT,%eax ret /* int futex_xchgl(int oparg, caddr_t uaddr, int *oldval); */ ENTRY(futex_xchgl) - movl PCPU(CURPCB), %eax - movl $futex_fault, PCB_ONFAULT(%eax) - movl 4(%esp), %eax - movl 8(%esp), %edx + movl PCPU(CURPCB),%eax + movl $futex_fault,PCB_ONFAULT(%eax) + movl 4(%esp),%eax + movl 8(%esp),%edx cmpl $VM_MAXUSER_ADDRESS,%edx ja futex_fault -#if defined(SMP) || !defined(_KERNEL) +#ifdef SMP lock #endif - xchgl %eax, (%edx) - movl 0xc(%esp), %edx - movl %eax, (%edx) - xorl %eax, %eax + xchgl %eax,(%edx) + movl 0xc(%esp),%edx + movl %eax,(%edx) + xorl %eax,%eax - movl PCPU(CURPCB), %edx - movl $0, PCB_ONFAULT(%edx) + movl PCPU(CURPCB),%edx + movl $0,PCB_ONFAULT(%edx) ret /* int futex_addl(int oparg, caddr_t uaddr, int *oldval); */ ENTRY(futex_addl) - movl PCPU(CURPCB), %eax - movl $futex_fault, PCB_ONFAULT(%eax) - movl 4(%esp), %eax - movl 8(%esp), %edx + movl PCPU(CURPCB),%eax + movl $futex_fault,PCB_ONFAULT(%eax) + movl 4(%esp),%eax + movl 8(%esp),%edx cmpl $VM_MAXUSER_ADDRESS,%edx ja futex_fault -#if defined(SMP) || !defined(_KERNEL) +#ifdef SMP lock #endif - xaddl %eax, (%edx) - movl 0xc(%esp), %edx - movl %eax, (%edx) - xorl %eax, %eax + xaddl %eax,(%edx) + movl 12(%esp),%edx + movl %eax,(%edx) + xorl %eax,%eax - movl PCPU(CURPCB), %edx - movl $0, PCB_ONFAULT(%edx) + movl PCPU(CURPCB),%edx + movl $0,PCB_ONFAULT(%edx) ret |