~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

TOMOYO Linux Cross Reference
Linux/arch/m68k/fpsp040/x_unimp.S

Version: ~ [ linux-6.12-rc7 ] ~ [ linux-6.11.7 ] ~ [ linux-6.10.14 ] ~ [ linux-6.9.12 ] ~ [ linux-6.8.12 ] ~ [ linux-6.7.12 ] ~ [ linux-6.6.60 ] ~ [ linux-6.5.13 ] ~ [ linux-6.4.16 ] ~ [ linux-6.3.13 ] ~ [ linux-6.2.16 ] ~ [ linux-6.1.116 ] ~ [ linux-6.0.19 ] ~ [ linux-5.19.17 ] ~ [ linux-5.18.19 ] ~ [ linux-5.17.15 ] ~ [ linux-5.16.20 ] ~ [ linux-5.15.171 ] ~ [ linux-5.14.21 ] ~ [ linux-5.13.19 ] ~ [ linux-5.12.19 ] ~ [ linux-5.11.22 ] ~ [ linux-5.10.229 ] ~ [ linux-5.9.16 ] ~ [ linux-5.8.18 ] ~ [ linux-5.7.19 ] ~ [ linux-5.6.19 ] ~ [ linux-5.5.19 ] ~ [ linux-5.4.285 ] ~ [ linux-5.3.18 ] ~ [ linux-5.2.21 ] ~ [ linux-5.1.21 ] ~ [ linux-5.0.21 ] ~ [ linux-4.20.17 ] ~ [ linux-4.19.323 ] ~ [ linux-4.18.20 ] ~ [ linux-4.17.19 ] ~ [ linux-4.16.18 ] ~ [ linux-4.15.18 ] ~ [ linux-4.14.336 ] ~ [ linux-4.13.16 ] ~ [ linux-4.12.14 ] ~ [ linux-4.11.12 ] ~ [ linux-4.10.17 ] ~ [ linux-4.9.337 ] ~ [ linux-4.4.302 ] ~ [ linux-3.10.108 ] ~ [ linux-2.6.32.71 ] ~ [ linux-2.6.0 ] ~ [ linux-2.4.37.11 ] ~ [ unix-v6-master ] ~ [ ccs-tools-1.8.12 ] ~ [ policy-sample ] ~
Architecture: ~ [ i386 ] ~ [ alpha ] ~ [ m68k ] ~ [ mips ] ~ [ ppc ] ~ [ sparc ] ~ [ sparc64 ] ~

Diff markup

Differences between /arch/m68k/fpsp040/x_unimp.S (Architecture i386) and /arch/m68k/fpsp040/x_unimp.S (Architecture m68k)


  1 |                                                   1 |
  2 |       x_unimp.sa 3.3 7/1/91                       2 |       x_unimp.sa 3.3 7/1/91
  3 |                                                   3 |
  4 |       fpsp_unimp --- FPSP handler for unimpl      4 |       fpsp_unimp --- FPSP handler for unimplemented instruction
  5 |       exception.                                  5 |       exception.
  6 |                                                   6 |
  7 | Invoked when the user program encounters a f      7 | Invoked when the user program encounters a floating-point
  8 | op-code that hardware does not support.  Tra      8 | op-code that hardware does not support.  Trap vector# 11
  9 | (See table 8-1 MC68030 User's Manual).            9 | (See table 8-1 MC68030 User's Manual).
 10 |                                                  10 |
 11 |                                                  11 |
 12 | Note: An fsave for an unimplemented inst. wi     12 | Note: An fsave for an unimplemented inst. will create a short
 13 | fsave stack.                                     13 | fsave stack.
 14 |                                                  14 |
 15 |  Input: 1. Six word stack frame for unimplem     15 |  Input: 1. Six word stack frame for unimplemented inst, four word
 16 |            for illegal                           16 |            for illegal
 17 |            (See table 8-7 MC68030 User's Man     17 |            (See table 8-7 MC68030 User's Manual).
 18 |         2. Unimp (short) fsave state frame c     18 |         2. Unimp (short) fsave state frame created here by fsave
 19 |            instruction.                          19 |            instruction.
 20 |                                                  20 |
 21 |                                                  21 |
 22 |               Copyright (C) Motorola, Inc. 1     22 |               Copyright (C) Motorola, Inc. 1990
 23 |                       All Rights Reserved        23 |                       All Rights Reserved
 24 |                                                  24 |
 25 |       For details on the license for this fi     25 |       For details on the license for this file, please see the
 26 |       file, README, in this same directory.      26 |       file, README, in this same directory.
 27                                                    27 
 28 X_UNIMP:        |idnt    2,1 | Motorola 040 Fl     28 X_UNIMP:        |idnt    2,1 | Motorola 040 Floating Point Software Package
 29                                                    29 
 30         |section        8                          30         |section        8
 31                                                    31 
 32 #include "fpsp.h"                                  32 #include "fpsp.h"
 33                                                    33 
 34         |xref   get_op                             34         |xref   get_op
 35         |xref   do_func                            35         |xref   do_func
 36         |xref   sto_res                            36         |xref   sto_res
 37         |xref   gen_except                         37         |xref   gen_except
 38         |xref   fpsp_fmt_error                     38         |xref   fpsp_fmt_error
 39                                                    39 
 40         .global fpsp_unimp                         40         .global fpsp_unimp
 41         .global uni_2                              41         .global uni_2
 42 fpsp_unimp:                                        42 fpsp_unimp:
 43         link            %a6,#-LOCAL_SIZE           43         link            %a6,#-LOCAL_SIZE
 44         fsave           -(%a7)                     44         fsave           -(%a7)
 45 uni_2:                                             45 uni_2:
 46         moveml          %d0-%d1/%a0-%a1,USER_D     46         moveml          %d0-%d1/%a0-%a1,USER_DA(%a6)
 47         fmovemx %fp0-%fp3,USER_FP0(%a6)            47         fmovemx %fp0-%fp3,USER_FP0(%a6)
 48         fmoveml %fpcr/%fpsr/%fpiar,USER_FPCR(%     48         fmoveml %fpcr/%fpsr/%fpiar,USER_FPCR(%a6)
 49         moveb           (%a7),%d0                  49         moveb           (%a7),%d0               |test for valid version num
 50         andib           #0xf0,%d0                  50         andib           #0xf0,%d0               |test for $4x
 51         cmpib           #VER_4,%d0      |must      51         cmpib           #VER_4,%d0      |must be $4x or exit
 52         bnel            fpsp_fmt_error             52         bnel            fpsp_fmt_error
 53 |                                                  53 |
 54 |       Temporary D25B Fix                         54 |       Temporary D25B Fix
 55 |       The following lines are used to ensure     55 |       The following lines are used to ensure that the FPSR
 56 |       exception byte and condition codes are     56 |       exception byte and condition codes are clear before proceeding
 57 |                                                  57 |
 58         movel           USER_FPSR(%a6),%d0         58         movel           USER_FPSR(%a6),%d0
 59         andl            #0xFF00FF,%d0   |clear     59         andl            #0xFF00FF,%d0   |clear all but accrued exceptions
 60         movel           %d0,USER_FPSR(%a6)         60         movel           %d0,USER_FPSR(%a6)
 61         fmovel          #0,%FPSR |clear all us     61         fmovel          #0,%FPSR |clear all user bits
 62         fmovel          #0,%FPCR        |clear     62         fmovel          #0,%FPCR        |clear all user exceptions for FPSP
 63                                                    63 
 64         clrb            UFLG_TMP(%a6)   |clr f     64         clrb            UFLG_TMP(%a6)   |clr flag for unsupp data
 65                                                    65 
 66         bsrl            get_op          |go ge     66         bsrl            get_op          |go get operand(s)
 67         clrb            STORE_FLG(%a6)             67         clrb            STORE_FLG(%a6)
 68         bsrl            do_func         |do th     68         bsrl            do_func         |do the function
 69         fsave           -(%a7)          |captu     69         fsave           -(%a7)          |capture possible exc state
 70         tstb            STORE_FLG(%a6)             70         tstb            STORE_FLG(%a6)
 71         bnes            no_store        |if ST     71         bnes            no_store        |if STORE_FLG is set, no store
 72         bsrl            sto_res         |store     72         bsrl            sto_res         |store the result in user space
 73 no_store:                                          73 no_store:
 74         bral            gen_except      |post      74         bral            gen_except      |post any exceptions and return
 75                                                    75 
 76         |end                                       76         |end
                                                      

~ [ source navigation ] ~ [ diff markup ] ~ [ identifier search ] ~

kernel.org | git.kernel.org | LWN.net | Project Home | SVN repository | Mail admin

Linux® is a registered trademark of Linus Torvalds in the United States and other countries.
TOMOYO® is a registered trademark of NTT DATA CORPORATION.

sflogo.php