Print this page
de-linting of .s files


   7  * with the License.
   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */
  22 /*
  23  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
  24  * Use is subject to license terms.
  25  */
  26 
  27 #pragma ident   "%Z%%M% %I%     %E% SMI"
  28 
  29 #include <sys/asm_linkage.h>
  30 #include <sys/machthread.h>
  31 #include <sys/privregs.h>
  32 #include <sys/machasi.h>
  33 #include <sys/trap.h>
  34 #include <sys/mmu.h>
  35 #include <sys/machparam.h>
  36 #include <sys/machtrap.h>
  37 #include <sys/traptrace.h>
  38 
  39 #if !defined(lint)
  40 #include "assym.h"
  41 
  42         /*
  43          * Spill fault handlers
  44          *   sn0 - spill normal tl 0
  45          *   sn1 - spill normal tl >0
  46          *   so0 - spill other tl 0
  47          *   so1 - spill other tl >0
  48          */
  49 
  50         ENTRY_NP(fault_32bit_sn0)
  51         !
  52         FAULT_WINTRACE(%g1, %g2, %g3, TT_F32_SN0)
  53         !
  54         ! Spill normal tl0 fault.
  55         ! This happens when a user tries to spill to an unmapped or
  56         ! misaligned stack. We handle an unmapped stack by simulating
  57         ! a pagefault at the trap pc and a misaligned stack by generating
  58         ! a user alignment trap.
  59         !


 496         b       .fault_fn1_common
 497           nop
 498         SET_SIZE(fault_64bit_fn1)
 499 
 500         ENTRY_NP(fault_rtt_fn1)
 501         FAULT_WINTRACE(%g1, %g2, %g3, TT_RTT_FN1)
 502         wrpr    %g0, 1, %gl
 503         b       .fault_fn1_common
 504           nop
 505         SET_SIZE(fault_rtt_fn1)
 506 
 507         /*
 508          * Kernel fault handlers
 509          */
 510         ENTRY_NP(fault_32bit_not)
 511         ENTRY_NP(fault_64bit_not)
 512         ba,pt   %xcc, ptl1_panic
 513         mov     PTL1_BAD_WTRAP, %g1
 514         SET_SIZE(fault_32bit_not)
 515         SET_SIZE(fault_64bit_not)
 516 #endif /* !lint */


   7  * with the License.
   8  *
   9  * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
  10  * or http://www.opensolaris.org/os/licensing.
  11  * See the License for the specific language governing permissions
  12  * and limitations under the License.
  13  *
  14  * When distributing Covered Code, include this CDDL HEADER in each
  15  * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
  16  * If applicable, add the following below this CDDL HEADER, with the
  17  * fields enclosed by brackets "[]" replaced with your own identifying
  18  * information: Portions Copyright [yyyy] [name of copyright owner]
  19  *
  20  * CDDL HEADER END
  21  */
  22 /*
  23  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
  24  * Use is subject to license terms.
  25  */
  26 


  27 #include <sys/asm_linkage.h>
  28 #include <sys/machthread.h>
  29 #include <sys/privregs.h>
  30 #include <sys/machasi.h>
  31 #include <sys/trap.h>
  32 #include <sys/mmu.h>
  33 #include <sys/machparam.h>
  34 #include <sys/machtrap.h>
  35 #include <sys/traptrace.h>
  36 

  37 #include "assym.h"
  38 
  39         /*
  40          * Spill fault handlers
  41          *   sn0 - spill normal tl 0
  42          *   sn1 - spill normal tl >0
  43          *   so0 - spill other tl 0
  44          *   so1 - spill other tl >0
  45          */
  46 
  47         ENTRY_NP(fault_32bit_sn0)
  48         !
  49         FAULT_WINTRACE(%g1, %g2, %g3, TT_F32_SN0)
  50         !
  51         ! Spill normal tl0 fault.
  52         ! This happens when a user tries to spill to an unmapped or
  53         ! misaligned stack. We handle an unmapped stack by simulating
  54         ! a pagefault at the trap pc and a misaligned stack by generating
  55         ! a user alignment trap.
  56         !


 493         b       .fault_fn1_common
 494           nop
 495         SET_SIZE(fault_64bit_fn1)
 496 
 497         ENTRY_NP(fault_rtt_fn1)
 498         FAULT_WINTRACE(%g1, %g2, %g3, TT_RTT_FN1)
 499         wrpr    %g0, 1, %gl
 500         b       .fault_fn1_common
 501           nop
 502         SET_SIZE(fault_rtt_fn1)
 503 
 504         /*
 505          * Kernel fault handlers
 506          */
 507         ENTRY_NP(fault_32bit_not)
 508         ENTRY_NP(fault_64bit_not)
 509         ba,pt   %xcc, ptl1_panic
 510         mov     PTL1_BAD_WTRAP, %g1
 511         SET_SIZE(fault_32bit_not)
 512         SET_SIZE(fault_64bit_not)