Index: /branches/arm/lisp-kernel/arm-macros.s
===================================================================
--- /branches/arm/lisp-kernel/arm-macros.s	(revision 13808)
+++ /branches/arm/lisp-kernel/arm-macros.s	(revision 13809)
@@ -498,47 +498,2 @@
         ')                
 
-/* Linux provides a weird kernel entrypoint to do cmpxchg on hardware
-   that may not support it natively.  Darwin only runs on ARMv6 hardware,
-   which can use ldrex/strex instructions to do cmpxchg inline.  On
-   SMP hardware, the cmpxchg should be followe by a 'dmb' (data memory
-   barrier) instruction, which is only available on ARMv7.  Confused yet?
-   The Linux kernel function clobbers some registers, and we may need
-   some support in pc_luser_xp() to fix things up at interrupt/suspend
-   time.
-   Generally, imm1 = mask with exactly one bit set, *imm2 = address of
-   refbits word. */
-
-define(`set_ref_bit',`
-        new_macro_labels()
-        __ifdef(`LINUX')
-        .globl set_ref_bit_entry_$1
-set_ref_bit_entry_$1:   
-        __(build_lisp_frame(imm0))  /* we clobber lr */
-        __(mov temp1,imm1)
-        __(mov temp2,rcontext)
-macro_label(again):     
-        __(ldr lr,macro_label(linux_kernel_cmpxchg))
-        __(ldr r0,[r2])
-        __(orr r1,r0,temp1)
-        __(blx lr)
-        .globl set_ref_bit_return_$1
-set_ref_bit_return_$1:   
-        __(mov rcontext,temp2)
-        __(ldr allocptr,[rcontext,#tcr.save_allocptr])
-        __(bcc macro_label(again))
-        __(restore_lisp_frame(imm0))
-        __(b macro_label(continue))
-macro_label(linux_kernel_cmpxchg):
-        .word 0xffff0fc0        /* magic address */
-macro_label(continue):
-        __endif
-        __ifdef(`DARWIN')
-macro_label(again):     
-        __(ldrex r0,[r2])
-        __(orr r0,r0,r1)
-        __(strex r0,r0,[r2])
-        __(cmp r0,#0)
-        __(bne macro_label(again))
-        __endif
-        ')
-                        
