1 /* 2 * EVENT_LOG system definitions 3 * 4 * Copyright (C) 2020, Broadcom. 5 * 6 * Unless you and Broadcom execute a separate written software license 7 * agreement governing use of this software, this software is licensed to you 8 * under the terms of the GNU General Public License version 2 (the "GPL"), 9 * available at http://www.broadcom.com/licenses/GPLv2.php, with the 10 * following added to such license: 11 * 12 * As a special exception, the copyright holders of this software give you 13 * permission to link this software with independent modules, and to copy and 14 * distribute the resulting executable under terms of your choice, provided that 15 * you also meet, for each linked independent module, the terms and conditions of 16 * the license of that module. An independent module is a module which is not 17 * derived from this software. The special exception does not apply to any 18 * modifications of the software. 19 * 20 * 21 * <<Broadcom-WL-IPTag/Dual:>> 22 */ 23 24 #ifndef _EVENT_LOG_SET_H_ 25 #define _EVENT_LOG_SET_H_ 26 27 /* Set assignments */ 28 #define EVENT_LOG_SET_BUS (0u) 29 #define EVENT_LOG_SET_WL (1u) 30 #define EVENT_LOG_SET_PSM (2u) 31 #define EVENT_LOG_SET_ERROR (3u) 32 33 /* MSCH logging */ 34 #define EVENT_LOG_SET_MSCH_PROFILER (4u) 35 36 /* A particular customer uses sets 5, 6, and 7. There is a request 37 * to not name these log sets as that could limit their ability to 38 * use different log sets in future. 39 * Sets 5, 6, and 7 are instantiated by host 40 * In such case, ecounters could be mapped to any set that host 41 * configures. They may or may not use set 5. 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 /* Temporary change to satisfy compilation across branches 49 * Will be removed after checkin 50 */ 51 #define EVENT_LOG_SET_8 (8u) 52 #define EVENT_LOG_SET_PRSRV (EVENT_LOG_SET_8) 53 54 #define EVENT_LOG_SET_9 (9u) 55 /* General purpose preserve chatty. 56 * EVENT_LOG_SET_PRSRV_CHATTY log set should not be used by FW as it is 57 * used by customer host. FW should use EVENT_LOG_SET_GP_PRSRV_CHATTY 58 * for general purpose preserve chatty logs. 59 */ 60 #define EVENT_LOG_SET_GP_PRSRV_CHATTY (EVENT_LOG_SET_9) 61 #define EVENT_LOG_SET_PRSRV_CHATTY (EVENT_LOG_SET_6) 62 63 /* BUS preserve */ 64 #define EVENT_LOG_SET_PRSRV_BUS (10u) 65 66 /* WL preserve */ 67 #define EVENT_LOG_SET_PRSRV_WL (11u) 68 69 /* Slotted BSS set */ 70 #define EVENT_LOG_SET_WL_SLOTTED_BSS (12u) 71 72 /* PHY entity logging */ 73 #define EVENT_LOG_SET_PHY (13u) 74 75 /* PHY preserve */ 76 #define EVENT_LOG_SET_PRSRV_PHY (14u) 77 78 /* RTE entity */ 79 #define EVENT_LOG_SET_RTE (15u) 80 81 /* Malloc and free logging */ 82 #define EVENT_LOG_SET_MEM_API (16u) 83 84 /* Console buffer */ 85 #define EVENT_LOG_SET_RTE_CONS_BUF (17u) 86 87 /* three log sets for general debug purposes */ 88 #define EVENT_LOG_SET_GENERAL_DBG_1 (18u) 89 #define EVENT_LOG_SET_GENERAL_DBG_2 (19u) 90 #define EVENT_LOG_SET_GENERAL_DBG_3 (20u) 91 92 /* Log sets for capturing power related logs. Note that these sets 93 * are to be used across entire system and not just WL. 94 */ 95 #define EVENT_LOG_SET_POWER_1 (21u) 96 #define EVENT_LOG_SET_POWER_2 (22u) 97 98 /* Used for timestamp plotting, TS_LOG() */ 99 #define EVENT_LOG_SET_TS_LOG (23u) 100 101 /* BUS preserve chatty */ 102 #define EVENT_LOG_SET_PRSRV_BUS_CHATTY (24u) 103 104 /* PRESERVE_PREIODIC_LOG_SET */ 105 /* flush if host is in D0 at every period */ 106 #define EVENT_LOG_SET_PRSV_PERIODIC (25u) 107 108 /* AMT logging and other related information */ 109 #define EVENT_LOG_SET_AMT (26u) 110 111 /* State machine logging. Part of preserve logs */ 112 #define EVENT_LOG_SET_FSM (27u) 113 114 /* wbus related logging */ 115 #define EVENT_LOG_SET_WBUS (28u) 116 117 /* bcm trace logging */ 118 #define EVENT_LOG_SET_BCM_TRACE (29u) 119 120 /* For PM alert related logging */ 121 #define EVENT_LOG_SET_WL_PS_LOG (30u) 122 123 #ifndef NUM_EVENT_LOG_SETS 124 /* Set a maximum number of sets here. It is not dynamic for 125 * efficiency of the EVENT_LOG calls. Old branches could define 126 * this to an appropriat enumber in their makefiles to reduce 127 * ROM invalidation 128 */ 129 #ifdef NUM_EVENT_LOG_SETS_V2 130 /* for v2, everything has became unsigned */ 131 #define NUM_EVENT_LOG_SETS (31u) 132 #else /* NUM_EVENT_LOG_SETS_V2 */ 133 #define NUM_EVENT_LOG_SETS (31) 134 #endif /* NUM_EVENT_LOG_SETS_V2 */ 135 #endif /* NUM_EVENT_LOG_SETS */ 136 137 /* send delayed logs when >= 50% of buffer is full */ 138 #ifndef ECOUNTERS_DELAYED_FLUSH_PERCENTAGE 139 #define ECOUNTERS_DELAYED_FLUSH_PERCENTAGE (50) 140 #endif 141 142 #endif /* _EVENT_LOG_SET_H_ */ 143