Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
ieee754xcpt.c
Go to the documentation of this file.
1 /*
2  * MIPS floating point support
3  * Copyright (C) 1994-2000 Algorithmics Ltd.
4  *
5  * ########################################################################
6  *
7  * This program is free software; you can distribute it and/or modify it
8  * under the terms of the GNU General Public License (Version 2) as
9  * published by the Free Software Foundation.
10  *
11  * This program is distributed in the hope it will be useful, but WITHOUT
12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13  * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14  * for more details.
15  *
16  * You should have received a copy of the GNU General Public License along
17  * with this program; if not, write to the Free Software Foundation, Inc.,
18  * 59 Temple Place - Suite 330, Boston MA 02111-1307, USA.
19  *
20  * ########################################################################
21  */
22 
23 /**************************************************************************
24  * Nov 7, 2000
25  * Added preprocessor hacks to map to Linux kernel diagnostics.
26  *
27  * Kevin D. Kissell, [email protected] and Carsten Langgaard, [email protected]
28  * Copyright (C) 2000 MIPS Technologies, Inc. All rights reserved.
29  *************************************************************************/
30 
31 #include <linux/kernel.h>
32 #include "ieee754.h"
33 
34 /*
35  * Very naff exception handler (you can plug in your own and
36  * override this).
37  */
38 
39 static const char *const rtnames[] = {
40  "sp", "dp", "xp", "si", "di"
41 };
42 
43 void ieee754_xcpt(struct ieee754xctx *xcp)
44 {
45  printk(KERN_DEBUG "floating point exception in \"%s\", type=%s\n",
46  xcp->op, rtnames[xcp->rt]);
47 }