Print this page
de-linting of .s files

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/sun4v/ml/mach_subr_asm.s
          +++ new/usr/src/uts/sun4v/ml/mach_subr_asm.s
↓ open down ↓ 18 lines elided ↑ open up ↑
  19   19   * CDDL HEADER END
  20   20   */
  21   21  /*
  22   22   * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
  23   23   */
  24   24  
  25   25  /*
  26   26   * General machine architecture & implementation specific
  27   27   * assembly language routines.
  28   28   */
  29      -#if defined(lint)
  30      -#include <sys/types.h>
  31      -#include <sys/t_lock.h>
  32      -#else   /* lint */
  33   29  #include "assym.h"
  34      -#endif  /* lint */
  35   30  
  36   31  #define CPU_MODULE /* need it for NSEC_SHIFT used by NATIVE_TIME_TO_NSEC() */
  37   32  
  38   33  #include <sys/asm_linkage.h>
  39   34  #include <sys/machsystm.h>
  40   35  #include <sys/machthread.h>
  41   36  #include <sys/machclock.h>
  42   37  #include <sys/privregs.h>
  43   38  #include <sys/cmpregs.h>
  44   39  #include <sys/clock.h>
  45   40  #include <sys/fpras.h>
  46   41  #include <sys/soft_state.h>
  47   42  
  48      -#if defined(lint)
  49      -
  50      -uint64_t
  51      -ultra_gettick(void)
  52      -{ return (0); }
  53      -
  54      -#else   /* lint */
  55      -
  56   43  /*
  57   44   * This isn't the routine you're looking for.
  58   45   *
  59   46   * The routine simply returns the value of %tick on the *current* processor.
  60   47   * Most of the time, gettick() [which in turn maps to %stick on platforms
  61   48   * that have different CPU %tick rates] is what you want.
  62   49   */
  63   50  
  64   51          ENTRY(ultra_gettick)
  65   52          RD_TICK(%o0,%o1,%o2,__LINE__)
  66   53          retl
  67   54          nop
  68   55          SET_SIZE(ultra_gettick)
  69   56  
  70      -#endif  /* lint */
  71      -
  72      -#if defined(lint)
  73      -/* ARGSUSED */
  74      -void
  75      -set_mmfsa_scratchpad(caddr_t vaddr)
  76      -{ }
  77      -
  78      -#else   /* lint */
  79      -
  80   57          ENTRY(set_mmfsa_scratchpad)
  81   58          stxa    %o0, [%g0]ASI_SCRATCHPAD 
  82   59          retl
  83   60          nop
  84   61          SET_SIZE(set_mmfsa_scratchpad)
  85      -#endif  /* lint */
  86   62  
  87      -#if defined(lint)
  88      -caddr_t
  89      -get_mmfsa_scratchpad()
  90      -{  return (0); }
  91      -
  92      -#else   /* lint */
  93      -
  94   63          ENTRY(get_mmfsa_scratchpad)
  95   64          ldxa    [%g0]ASI_SCRATCHPAD, %o0 
  96   65          retl
  97   66          nop
  98   67          SET_SIZE(get_mmfsa_scratchpad)
  99      -#endif  /* lint */
 100   68  
 101   69  
 102   70  
 103      -#if defined(lint)
 104      -/* ARGSUSED */
 105      -void
 106      -cpu_intrq_unregister_powerdown(uint64_t doneflag_va)
 107      -{}
 108      -
 109      -#else   /* lint */
 110      -
 111   71  /*
 112   72   * Called from a x-trap at tl1 must use %g1 as arg
 113   73   * and save/restore %o0-%o5 after hypervisor calls
 114   74   */
 115   75  
 116   76          ENTRY(cpu_intrq_unregister_powerdown)
 117   77  
 118   78          CPU_ADDR(%g2, %g3)
 119   79          add %g2, CPU_MCPU, %g2 
 120   80          /*
↓ open down ↓ 41 lines elided ↑ open up ↑
 162  122           * This CPU is on its way out. Spin here
 163  123           * until the DR unconfigure code stops it.
 164  124           * Returning would put it back in the OS
 165  125           * where it might grab resources like locks,
 166  126           * causing some nastiness to occur.
 167  127           */
 168  128  0:
 169  129          ba,a    0b
 170  130  
 171  131          SET_SIZE(cpu_intrq_unregister_powerdown)
 172      -#endif  /* lint */
 173  132  
 174  133  
 175      -#if defined(lint)
 176      -/* ARGSUSED */
 177      -int
 178      -getprocessorid(void)
 179      -{ return (0); }
 180      -
 181      -#else   /* lint */
 182      -
 183  134  /*
 184  135   * Get the processor ID.
 185  136   * === MID reg as specified in 15dec89 sun4u spec, sec 5.4.3
 186  137   */
 187  138  
 188  139          ENTRY(getprocessorid)
 189  140          CPU_INDEX(%o0, %o1)
 190  141          retl
 191  142          nop
 192  143          SET_SIZE(getprocessorid)
 193  144  
 194      -#endif  /* lint */
 195      -
 196      -#if defined(lint) || defined(__lint)
 197      -
 198      -/* ARGSUSED */
 199      -hrtime_t
 200      -tick2ns(hrtime_t tick, uint_t cpuid)
 201      -{ return 0; }
 202      -
 203      -#else   /* lint */
 204      -
 205  145          ENTRY_NP(tick2ns)
 206  146          !
 207  147          ! Use nsec_scale for sun4v which is based on %stick
 208  148          !
 209  149          NATIVE_TIME_TO_NSEC(%o0, %o2, %o3)
 210  150          retl
 211  151          nop
 212  152          SET_SIZE(tick2ns)
 213  153  
 214      -#endif  /* lint */
 215      -
 216      -#if defined(lint)
 217      -
 218      -/* ARGSUSED */
 219      -void
 220      -set_cmp_error_steering(void)
 221      -{}
 222      -
 223      -#else   /* lint */
 224      -
 225  154          ENTRY(set_cmp_error_steering)
 226  155          retl
 227  156          nop
 228  157          SET_SIZE(set_cmp_error_steering)
 229  158  
 230      -#endif  /* lint */
 231      -
 232      -#if defined(lint)
 233      -
 234      -/* ARGSUSED */
 235      -uint64_t
 236      -ultra_getver(void)
 237      -{
 238      -        return (0); 
 239      -}
 240      -
 241      -#else /* lint */
 242      -
 243  159          ENTRY(ultra_getver)
 244  160          retl
 245  161          mov     -1, %o0         ! XXXQ no version available
 246  162          SET_SIZE(ultra_getver)
 247  163  
 248      -#endif /* lint */
 249      -
 250      -#if defined(lint)
 251      -
 252      -int
 253      -fpras_chkfn_type1(void)
 254      -{ return 0; }
 255      -
 256      -#else   /* lint */
 257      -
 258  164          /*
 259  165           * Check instructions using just the AX pipelines, designed by
 260  166           * C.B. Liaw of PNP.
 261  167           *
 262  168           * This function must match a struct fpras_chkfn and must be
 263  169           * block aligned.  A zero return means all was well.  These
 264  170           * instructions are chosen to be sensitive to bit corruptions
 265  171           * on the fpras rewrite, so if a bit corruption still produces
 266  172           * a valid instruction we should still get an incorrect result
 267  173           * here.  This function is never called directly - it is copied
↓ open down ↓ 139 lines elided ↑ open up ↑
 407  313          retl                            ! 5
 408  314            mov   CBO2, CBR2              ! 6, restore borrowed register
 409  315          .skip 4*(13-7+1)                ! 7 - 13
 410  316                                          !
 411  317                                          ! illegal instr'n trap comes here
 412  318                                          !
 413  319          mov     CBO2, CBR2              ! 14, restore borrowed register
 414  320          retl                            ! 15
 415  321            mov   FPRAS_BADTRAP, %o0      ! 16, how detected
 416  322          SET_SIZE(fpras_chkfn_type1)
 417      -#endif  /* lint */
 418  323  
 419      -#if defined(lint)
 420      -char    soft_state_message_strings[SOLARIS_SOFT_STATE_MSG_CNT][SSM_SIZE];
 421      -#else   /* lint */
 422  324          .seg    ".data"
 423  325          .global soft_state_message_strings
 424  326  
 425  327          .align  SSM_SIZE
 426  328  soft_state_message_strings:
 427  329          .asciz  SOLARIS_SOFT_STATE_BOOT_MSG_STR
 428  330          .align  SSM_SIZE
 429  331          .asciz  SOLARIS_SOFT_STATE_RUN_MSG_STR
 430  332          .align  SSM_SIZE
 431  333          .asciz  SOLARIS_SOFT_STATE_HALT_MSG_STR
↓ open down ↓ 3 lines elided ↑ open up ↑
 435  337          .asciz  SOLARIS_SOFT_STATE_PANIC_MSG_STR
 436  338          .align  SSM_SIZE
 437  339          .asciz  SOLARIS_SOFT_STATE_REBOOT_MSG_STR
 438  340          .align  SSM_SIZE
 439  341          .asciz  SOLARIS_SOFT_STATE_DEBUG_MSG_STR
 440  342          .align  SSM_SIZE
 441  343          .skip   SSM_SIZE                        /* saved message */
 442  344          .nword  0
 443  345  
 444  346          .seg    ".text"
 445      -#endif  /* lint */
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX