• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * EVENT_LOG system definitions
4  *
5  * Copyright (C) 1999-2019, Broadcom.
6  *
7  *      Unless you and Broadcom execute a separate written software license
8  * agreement governing use of this software, this software is licensed to you
9  * under the terms of the GNU General Public License version 2 (the "GPL"),
10  * available at http://www.broadcom.com/licenses/GPLv2.php, with the
11  * following added to such license:
12  *
13  *      As a special exception, the copyright holders of this software give you
14  * permission to link this software with independent modules, and to copy and
15  * distribute the resulting executable under terms of your choice, provided that
16  * you also meet, for each linked independent module, the terms and conditions of
17  * the license of that module.  An independent module is a module which is not
18  * derived from this software.  The special exception does not apply to any
19  * modifications of the software.
20  *
21  *      Notwithstanding the above, under no circumstances may you combine this
22  * software in any way with any other Broadcom software provided under a license
23  * other than the GPL, without Broadcom's express prior written consent.
24  *
25  *
26  * <<Broadcom-WL-IPTag/Open:>>
27  *
28  * $Id: event_log_set.h 818566 2019-05-08 04:01:45Z $
29  */
30 
31 #ifndef _EVENT_LOG_SET_H_
32 #define _EVENT_LOG_SET_H_
33 
34 /* Set assignments */
35 #define EVENT_LOG_SET_BUS		(0u)
36 #define EVENT_LOG_SET_WL		(1u)
37 #define EVENT_LOG_SET_PSM		(2u)
38 #define EVENT_LOG_SET_ERROR		(3u)
39 
40 /* MSCH logging */
41 #define EVENT_LOG_SET_MSCH_PROFILER	(4u)
42 
43 #define EVENT_LOG_SET_5			(5u)
44 #define EVENT_LOG_SET_ECOUNTERS		(EVENT_LOG_SET_5)
45 #define EVENT_LOG_SET_6			(6u)
46 #define EVENT_LOG_SET_7			(7u)
47 
48 #define EVENT_LOG_SET_8			(8u)
49 #define EVENT_LOG_SET_PRSRV		(EVENT_LOG_SET_8)
50 
51 #define EVENT_LOG_SET_9			(9u)
52 /* General purpose preserve chatty.
53  * EVENT_LOG_SET_PRSRV_CHATTY log set should not be used by FW as it is
54  * used by customer host. FW should use EVENT_LOG_SET_GP_PRSRV_CHATTY
55  * for general purpose preserve chatty logs.
56  */
57 #define EVENT_LOG_SET_GP_PRSRV_CHATTY	(EVENT_LOG_SET_9)
58 #define EVENT_LOG_SET_PRSRV_CHATTY	(EVENT_LOG_SET_6)
59 
60 /* BUS preserve */
61 #define EVENT_LOG_SET_PRSRV_BUS		(10u)
62 
63 /* WL preserve */
64 #define EVENT_LOG_SET_PRSRV_WL		(11u)
65 
66 /* Slotted BSS set */
67 #define EVENT_LOG_SET_WL_SLOTTED_BSS    (12u)
68 
69 /* PHY entity logging */
70 #define EVENT_LOG_SET_PHY		(13u)
71 
72 /* PHY preserve */
73 #define EVENT_LOG_SET_PRSRV_PHY		(14u)
74 
75 /* RTE entity */
76 #define EVENT_LOG_SET_RTE		(15u)
77 
78 /* Malloc and free logging */
79 #define EVENT_LOG_SET_MEM_API		(16u)
80 
81 /* Console buffer */
82 #define EVENT_LOG_SET_RTE_CONS_BUF	(17u)
83 
84 /* three log sets for general debug purposes */
85 #define EVENT_LOG_SET_GENERAL_DBG_1	(18u)
86 #define EVENT_LOG_SET_GENERAL_DBG_2	(19u)
87 #define EVENT_LOG_SET_GENERAL_DBG_3	(20u)
88 
89 /* Log sets for capturing power related logs. Note that these sets
90  * are to be used across entire system and not just WL.
91  */
92 #define EVENT_LOG_SET_POWER_1		(21u)
93 #define EVENT_LOG_SET_POWER_2		(22u)
94 
95 /* Used for timestamp plotting, TS_LOG() */
96 #define EVENT_LOG_SET_TS_LOG		(23u)
97 
98 /* BUS preserve chatty */
99 #define EVENT_LOG_SET_PRSRV_BUS_CHATTY	(24u)
100 
101 /* PRESERVE_PREIODIC_LOG_SET */
102 /* flush if host is in D0 at every period */
103 #define EVENT_LOG_SET_PRSV_PERIODIC	(25u)
104 
105 #ifndef NUM_EVENT_LOG_SETS
106 /* Set a maximum number of sets here.  It is not dynamic for
107  * efficiency of the EVENT_LOG calls. Old branches could define
108  * this to an appropriat enumber in their makefiles to reduce
109  * ROM invalidation
110  */
111 #ifdef NUM_EVENT_LOG_SETS_V2
112 /* for v2, everything has became unsigned */
113 #define NUM_EVENT_LOG_SETS (26u)
114 #else /* NUM_EVENT_LOG_SETS_V2 */
115 #define NUM_EVENT_LOG_SETS (26)
116 #endif /* NUM_EVENT_LOG_SETS_V2 */
117 #endif /* NUM_EVENT_LOG_SETS */
118 
119 /* send delayed logs when >= 50% of buffer is full */
120 #ifndef ECOUNTERS_DELAYED_FLUSH_PERCENTAGE
121 #define ECOUNTERS_DELAYED_FLUSH_PERCENTAGE	(50)
122 #endif // endif
123 
124 #endif /* _EVENT_LOG_SET_H_ */
125