1 /****************************************************************************** 2 * 3 * Copyright (C) 2002-2012 Broadcom Corporation 4 * 5 * Licensed under the Apache License, Version 2.0 (the "License"); 6 * you may not use this file except in compliance with the License. 7 * You may obtain a copy of the License at: 8 * 9 * http://www.apache.org/licenses/LICENSE-2.0 10 * 11 * Unless required by applicable law or agreed to in writing, software 12 * distributed under the License is distributed on an "AS IS" BASIS, 13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 * See the License for the specific language governing permissions and 15 * limitations under the License. 16 * 17 ******************************************************************************/ 18 #ifndef DYN_MEM_H 19 #define DYN_MEM_H 20 21 #include "common/bluedroid_user_config.h" 22 23 #if UC_BT_BLE_DYNAMIC_ENV_MEMORY 24 #define BTU_DYNAMIC_MEMORY TRUE 25 #define BTM_DYNAMIC_MEMORY TRUE 26 #define L2C_DYNAMIC_MEMORY TRUE 27 #define GATT_DYNAMIC_MEMORY TRUE 28 #define SMP_DYNAMIC_MEMORY TRUE 29 #define BTA_DYNAMIC_MEMORY TRUE 30 #define SDP_DYNAMIC_MEMORY TRUE 31 #define GAP_DYNAMIC_MEMORY TRUE 32 #define RFC_DYNAMIC_MEMORY TRUE 33 #define TCS_DYNAMIC_MEMORY TRUE 34 #define BNEP_DYNAMIC_MEMORY TRUE 35 #define AVDT_DYNAMIC_MEMORY TRUE 36 #define AVCT_DYNAMIC_MEMORY TRUE 37 #define MCA_DYNAMIC_MEMORY TRUE 38 #define A2D_DYNAMIC_MEMORY TRUE 39 #define VDP_DYNAMIC_MEMORY TRUE 40 #define AVRC_DYNAMIC_MEMORY TRUE 41 #define BIP_DYNAMIC_MEMORY TRUE 42 #define BPP_DYNAMIC_MEMORY TRUE 43 #define CTP_DYNAMIC_MEMORY TRUE 44 #define FTP_DYNAMIC_MEMORY TRUE 45 #define HCRP_DYNAMIC_MEMORY TRUE 46 #define HFP_DYNAMIC_MEMORY TRUE 47 #define HID_DYNAMIC_MEMORY TRUE 48 #define HSP2_DYNAMIC_MEMORY TRUE 49 #define ICP_DYNAMIC_MEMORY TRUE 50 #define OPP_DYNAMIC_MEMORY TRUE 51 #define PAN_DYNAMIC_MEMORY TRUE 52 #define SPP_DYNAMIC_MEMORY TRUE 53 #define SLIP_DYNAMIC_MEMORY TRUE 54 #define LLCP_DYNAMIC_MEMORY TRUE 55 #define BTC_SBC_DEC_DYNAMIC_MEMORY TRUE 56 57 #else /* #if UC_BT_BLE_DYNAMIC_ENV_MEMORY */ 58 #define BTU_DYNAMIC_MEMORY FALSE 59 #define BTM_DYNAMIC_MEMORY FALSE 60 #define L2C_DYNAMIC_MEMORY FALSE 61 #define GATT_DYNAMIC_MEMORY FALSE 62 #define SMP_DYNAMIC_MEMORY FALSE 63 #define BTA_DYNAMIC_MEMORY FALSE 64 #define SDP_DYNAMIC_MEMORY FALSE 65 #define GAP_DYNAMIC_MEMORY FALSE 66 #define RFC_DYNAMIC_MEMORY FALSE 67 #define TCS_DYNAMIC_MEMORY FALSE 68 #define BNEP_DYNAMIC_MEMORY FALSE 69 #define AVDT_DYNAMIC_MEMORY FALSE 70 #define AVCT_DYNAMIC_MEMORY FALSE 71 #define MCA_DYNAMIC_MEMORY FALSE 72 #define A2D_DYNAMIC_MEMORY FALSE 73 #define VDP_DYNAMIC_MEMORY FALSE 74 #define AVRC_DYNAMIC_MEMORY FALSE 75 #define BIP_DYNAMIC_MEMORY FALSE 76 #define BPP_DYNAMIC_MEMORY FALSE 77 #define CTP_DYNAMIC_MEMORY FALSE 78 #define FTP_DYNAMIC_MEMORY FALSE 79 #define HCRP_DYNAMIC_MEMORY FALSE 80 #define HFP_DYNAMIC_MEMORY FALSE 81 #define HID_DYNAMIC_MEMORY FALSE 82 #define HSP2_DYNAMIC_MEMORY FALSE 83 #define ICP_DYNAMIC_MEMORY FALSE 84 #define OPP_DYNAMIC_MEMORY FALSE 85 #define PAN_DYNAMIC_MEMORY FALSE 86 #define SPP_DYNAMIC_MEMORY FALSE 87 #define SLIP_DYNAMIC_MEMORY FALSE 88 #define LLCP_DYNAMIC_MEMORY FALSE 89 #define BTC_SBC_DEC_DYNAMIC_MEMORY FALSE 90 91 #endif /* #if UC_BT_BLE_DYNAMIC_ENV_MEMORY */ 92 93 94 /**************************************************************************** 95 ** Define memory usage for each CORE component (if not defined in bdroid_buildcfg.h) 96 ** The default for each component is to use static memory allocations. 97 */ 98 #ifndef BTU_DYNAMIC_MEMORY 99 #define BTU_DYNAMIC_MEMORY FALSE 100 #endif 101 102 #ifndef BTM_DYNAMIC_MEMORY 103 #define BTM_DYNAMIC_MEMORY FALSE 104 #endif 105 106 #ifndef SDP_DYNAMIC_MEMORY 107 #define SDP_DYNAMIC_MEMORY FALSE 108 #endif 109 110 #ifndef GAP_DYNAMIC_MEMORY 111 #define GAP_DYNAMIC_MEMORY FALSE 112 #endif 113 114 #ifndef L2C_DYNAMIC_MEMORY 115 #define L2C_DYNAMIC_MEMORY FALSE 116 #endif 117 118 #ifndef RFC_DYNAMIC_MEMORY 119 #define RFC_DYNAMIC_MEMORY FALSE 120 #endif 121 122 #ifndef TCS_DYNAMIC_MEMORY 123 #define TCS_DYNAMIC_MEMORY FALSE 124 #endif 125 126 #ifndef BNEP_DYNAMIC_MEMORY 127 #define BNEP_DYNAMIC_MEMORY FALSE 128 #endif 129 130 #ifndef AVDT_DYNAMIC_MEMORY 131 #define AVDT_DYNAMIC_MEMORY FALSE 132 #endif 133 134 #ifndef AVCT_DYNAMIC_MEMORY 135 #define AVCT_DYNAMIC_MEMORY FALSE 136 #endif 137 138 #ifndef MCA_DYNAMIC_MEMORY 139 #define MCA_DYNAMIC_MEMORY FALSE 140 #endif 141 142 #ifndef GATT_DYNAMIC_MEMORY 143 #define GATT_DYNAMIC_MEMORY FALSE 144 #endif 145 146 #ifndef SMP_DYNAMIC_MEMORY 147 #define SMP_DYNAMIC_MEMORY FALSE 148 #endif 149 150 /**************************************************************************** 151 ** Define memory usage for each PROFILE component (if not defined in bdroid_buildcfg.h) 152 ** The default for each component is to use static memory allocations. 153 */ 154 #ifndef A2D_DYNAMIC_MEMORY 155 #define A2D_DYNAMIC_MEMORY FALSE 156 #endif 157 158 #ifndef VDP_DYNAMIC_MEMORY 159 #define VDP_DYNAMIC_MEMORY FALSE 160 #endif 161 162 #ifndef AVRC_DYNAMIC_MEMORY 163 #define AVRC_DYNAMIC_MEMORY FALSE 164 #endif 165 166 #ifndef BIP_DYNAMIC_MEMORY 167 #define BIP_DYNAMIC_MEMORY FALSE 168 #endif 169 170 #ifndef BPP_DYNAMIC_MEMORY 171 #define BPP_DYNAMIC_MEMORY FALSE 172 #endif 173 174 #ifndef CTP_DYNAMIC_MEMORY 175 #define CTP_DYNAMIC_MEMORY FALSE 176 #endif 177 178 #ifndef FTP_DYNAMIC_MEMORY 179 #define FTP_DYNAMIC_MEMORY FALSE 180 #endif 181 182 #ifndef HCRP_DYNAMIC_MEMORY 183 #define HCRP_DYNAMIC_MEMORY FALSE 184 #endif 185 186 #ifndef HFP_DYNAMIC_MEMORY 187 #define HFP_DYNAMIC_MEMORY FALSE 188 #endif 189 190 #ifndef HID_DYNAMIC_MEMORY 191 #define HID_DYNAMIC_MEMORY FALSE 192 #endif 193 194 #ifndef HSP2_DYNAMIC_MEMORY 195 #define HSP2_DYNAMIC_MEMORY FALSE 196 #endif 197 198 #ifndef ICP_DYNAMIC_MEMORY 199 #define ICP_DYNAMIC_MEMORY FALSE 200 #endif 201 202 #ifndef OPP_DYNAMIC_MEMORY 203 #define OPP_DYNAMIC_MEMORY FALSE 204 #endif 205 206 #ifndef PAN_DYNAMIC_MEMORY 207 #define PAN_DYNAMIC_MEMORY FALSE 208 #endif 209 210 #ifndef SPP_DYNAMIC_MEMORY 211 #define SPP_DYNAMIC_MEMORY FALSE 212 #endif 213 214 #ifndef SLIP_DYNAMIC_MEMORY 215 #define SLIP_DYNAMIC_MEMORY FALSE 216 #endif 217 218 #ifndef LLCP_DYNAMIC_MEMORY 219 #define LLCP_DYNAMIC_MEMORY FALSE 220 #endif 221 222 /**************************************************************************** 223 ** Define memory usage for BTA and BTC (if not defined in bdroid_buildcfg.h) 224 ** The default for each component is to use static memory allocations. 225 */ 226 #ifndef BTA_DYNAMIC_MEMORY 227 #define BTA_DYNAMIC_MEMORY FALSE 228 #endif 229 230 #ifndef BTC_DYNAMIC_MEMORY 231 #define BTC_DYNAMIC_MEMORY FALSE 232 #endif 233 234 #endif /* #ifdef DYN_MEM_H */ 235