Print this page
de-linting of .s files

@@ -28,16 +28,12 @@
  * This file is through cpp before being used as
  * an inline.  It contains support routines used
  * only by DR for the copy-rename sequence.
  */
 
-#if defined(lint)
-#include <sys/types.h>
-#else
 #include "assym.h"
 #include "drmach_offsets.h"
-#endif /* lint */
 
 #include <sys/asm_linkage.h>
 #include <sys/param.h>
 #include <sys/privregs.h>
 #include <sys/spitregs.h>

@@ -49,12 +45,10 @@
 #include <sys/intreg.h>
 #include <sys/cheetahregs.h>
 #include <sys/drmach.h>
 #include <sys/sbd_ioctl.h>
 
-#if !defined(lint)
-
 /*
  * turn off speculative mode to prevent unwanted memory access
  * when we are in the FMEM loops
  */
 

@@ -66,19 +60,12 @@
         set     1, tmp2                                                 ;\
         sllx    tmp2, MCNTL_SPECULATIVE_SHIFT, tmp2                                             ;\
         or      tmp1, tmp2, tmp1                                        ;\
         stxa    tmp1, [%g0]ASI_MCNTL                                    ;\
         membar #Sync
-#endif
 
 
-#if defined(lint)
-/*ARGSUSED*/
-void
-drmach_fmem_loop_script(caddr_t critical, int size, caddr_t stat)
-{ return; }
-#else /* lint */
         .align  8
         ENTRY_NP(drmach_fmem_loop_script)
         /* turn off speculative mode */
         FJSV_SPECULATIVE_OFF(%o5, %o3, %o4);
 

@@ -156,33 +143,19 @@
          * we put sleep instruction in the delay slot
          */
         ba      2b
 .word    0x81b01060
         SET_SIZE(drmach_fmem_loop_script)
-#endif /* lint */
 
-#if defined(lint)
-/*ARGSUSED*/
-void
-drmach_flush_icache(void)
-{ return; }
-#else /* lint */
         .align  8
         ENTRY_NP(drmach_flush_icache)
         stxa    %g0, [%g0]ASI_ALL_FLUSH_L1I
         membar  #Sync
         retl
          nop
         SET_SIZE(drmach_flush_icache)
-#endif
 
-#if defined(lint)
-/*ARGSUSED*/
-int
-drmach_fmem_exec_script(caddr_t critical, int size)
-{ return (0); }
-#else /* lint */
 .align 32
         ENTRY_NP(drmach_fmem_exec_script)
         /* turn off speculative mode */
         FJSV_SPECULATIVE_OFF(%o5, %o3, %o4);
         /* save locals to save area */

@@ -453,33 +426,15 @@
         /* we are done or timed out */
 6:
         ba,a    1b
          nop
         SET_SIZE(drmach_fmem_exec_script)
-#endif /* lint */
 
-#if defined(lint)
-/*ARGSUSED*/
-void
-drmach_fmem_exec_script_end(caddr_t critical, int size)
-{ return; }
-#else /* lint */
         ENTRY_NP(drmach_fmem_exec_script_end)
         nop
         SET_SIZE(drmach_fmem_exec_script_end)
-#endif /* lint */
 
-#if defined(lint)
-uint64_t
-patch_inst(uint64_t *x, uint64_t y)
-{
-        *x = y;
-        return (0);
-}
-
-#else   /* lint */
-
         ENTRY_NP(patch_inst)
         ldx     [%o0], %o2
         casx    [%o0], %o2, %o1
         flush   %o0
         membar #Sync

@@ -486,46 +441,22 @@
         ldx     [%o0], %o2
         retl
          mov    %o2, %o0
         SET_SIZE(patch_inst)
 
-#endif /* lint */
-
-#if defined(lint)
-void
-drmach_sys_trap()
-{
-}
-#else   /* lint */
         ENTRY_NP(drmach_sys_trap)
         mov     -1, %g4
         set     sys_trap, %g5
         jmp     %g5
          nop
         SET_SIZE(drmach_sys_trap)
-#endif /* lint */
 
-#if defined(lint)
-uint64_t
-drmach_get_stick()
-{
-        return (0);
-}
-#else   /* lint */
         ENTRY_NP(drmach_get_stick)
         retl
         rd      STICK, %o0
         SET_SIZE(drmach_get_stick)
-#endif /* lint */
 
-#if defined(lint)
-/*ARGSUSED*/
-void
-drmach_flush(drmach_copy_rename_critical_t *x, uint_t y)
-{}
-
-#else /* lint */
         ENTRY_NP(drmach_flush)
         mov     %o0, %o2
 0:
         flush   %o2
         sub     %o1, 8, %o1

@@ -532,6 +463,5 @@
         brnz    %o1, 0b
          add    %o2, 8, %o2
         retl
          nop
         SET_SIZE(drmach_flush)
-#endif /* lint */