1 /******************************************************************************
4 * Project: Gigabit Ethernet Adapters, Common Modules
5 * Version: $Revision: 1.14 $
6 * Date: $Date: 2003/05/13 17:26:00 $
7 * Purpose: SK specific DEBUG support
9 ******************************************************************************/
11 /******************************************************************************
13 * (C)Copyright 1998-2002 SysKonnect.
14 * (C)Copyright 2002-2003 Marvell.
16 * This program is free software; you can redistribute it and/or modify
17 * it under the terms of the GNU General Public License as published by
18 * the Free Software Foundation; either version 2 of the License, or
19 * (at your option) any later version.
21 * The information in this file is provided "AS IS" without warranty.
23 ******************************************************************************/
25 /******************************************************************************
29 * Revision 1.14 2003/05/13 17:26:00 mkarl
32 * Revision 1.13 2003/03/31 07:16:39 mkarl
33 * Corrected Copyright.
35 * Revision 1.12 2002/07/15 15:37:13 rschmidt
36 * Power Management support
39 * Revision 1.11 2002/04/25 11:04:39 rschmidt
42 * Revision 1.10 1999/11/22 13:47:40 cgoos
43 * Changed license header to GPL.
45 * Revision 1.9 1999/09/14 14:02:43 rwahl
46 * Added SK_DBGMOD_PECP.
48 * Revision 1.8 1998/11/25 08:31:54 gklug
49 * fix: no C++ comments allowed in common sources
51 * Revision 1.7 1998/11/24 16:47:24 swolf
52 * Driver may now define its own SK_DBG_MSG() (eg. in "h/skdrv1st.h").
54 * Revision 1.6 1998/10/28 10:23:55 rassmann
55 * ADDED SK_DBGMOD_ADDR.
57 * Revision 1.5 1998/10/22 09:43:55 gklug
60 * Revision 1.4 1998/10/01 07:54:44 gklug
61 * add: PNMI debug module
63 * Revision 1.3 1998/09/18 08:32:34 afischer
64 * Macros changed according ssr-spec.:
65 * SK_DBG_MODCHK -> SK_DBG_CHKMOD
66 * SK_DBG_CATCHK -> SK_DBG_CHKCAT
68 * Revision 1.2 1998/07/03 14:38:25 malthoff
69 * Add category SK_DBGCAT_FATAL.
71 * Revision 1.1 1998/06/19 13:39:01 malthoff
75 ******************************************************************************/
77 #ifndef __INC_SKDEBUG_H
78 #define __INC_SKDEBUG_H
82 #define SK_DBG_MSG(pAC,comp,cat,arg) \
83 if ( ((comp) & SK_DBG_CHKMOD(pAC)) && \
84 ((cat) & SK_DBG_CHKCAT(pAC)) ) { \
89 #define SK_DBG_MSG(pAC,comp,lev,arg)
94 * Due to any restrictions of kernel printf routines do not use other
95 * format identifiers as: %x %d %c %s .
96 * Never use any combined format identifiers such as: %lx %ld in your
97 * printf - argument (arg) because some OS specific kernel printfs may
98 * only support some basic identifiers.
103 #define SK_DBGMOD_MERR 0x00000001L /* general module error indication */
104 #define SK_DBGMOD_HWM 0x00000002L /* Hardware init module */
105 #define SK_DBGMOD_RLMT 0x00000004L /* RLMT module */
106 #define SK_DBGMOD_VPD 0x00000008L /* VPD module */
107 #define SK_DBGMOD_I2C 0x00000010L /* I2C module */
108 #define SK_DBGMOD_PNMI 0x00000020L /* PNMI module */
109 #define SK_DBGMOD_CSUM 0x00000040L /* CSUM module */
110 #define SK_DBGMOD_ADDR 0x00000080L /* ADDR module */
111 #define SK_DBGMOD_PECP 0x00000100L /* PECP module */
112 #define SK_DBGMOD_POWM 0x00000200L /* Power Management module */
116 #define SK_DBGCAT_INIT 0x00000001L /* module/driver initialization */
117 #define SK_DBGCAT_CTRL 0x00000002L /* controlling devices */
118 #define SK_DBGCAT_ERR 0x00000004L /* error handling paths */
119 #define SK_DBGCAT_TX 0x00000008L /* transmit path */
120 #define SK_DBGCAT_RX 0x00000010L /* receive path */
121 #define SK_DBGCAT_IRQ 0x00000020L /* general IRQ handling */
122 #define SK_DBGCAT_QUEUE 0x00000040L /* any queue management */
123 #define SK_DBGCAT_DUMP 0x00000080L /* large data output e.g. hex dump */
124 #define SK_DBGCAT_FATAL 0x00000100L /* fatal error */
126 #endif /* __INC_SKDEBUG_H */