Commit ddeeecd
bluetooth: host: Add a check for num of bt_conn_tx and ACL/ISO bufs
After #72090, each
packet to be sent (wether ACL or ISO data) has a corresponding
`bt_conn_tx` object, regardless of whether a callback is used.
This means that number of packets Host can send to Controller is limited
by the smaller of two values: ACL/ISO packets Controller can receive,
and the number of `bt_conn_tx` objects allocated by Host.
A mismatch between these numbers may lead to inefficient resource usage
on either Host or Controller side. If Host allocates fewer `bt_conn_tx`
objects than the number of buffers available on Controller for a given
data type, some Controller buffers may go unused. Conversely, if Host
allocates more `bt_conn_tx` objects than Controller can consume, the
excess objects remain unused.
This commit adds a check and issues a warning if the number of
`bt_conn_tx` objects is not aligned with the number of ACL/ISO buffers
reported by Controller via the LE Read Buffer Size v1 or v2 command.
Signed-off-by: Pavel Vasilyev <[email protected]>1 parent 1ee5123 commit ddeeecd
1 file changed
+26
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
95 | 115 | | |
96 | 116 | | |
97 | 117 | | |
| |||
3145 | 3165 | | |
3146 | 3166 | | |
3147 | 3167 | | |
| 3168 | + | |
| 3169 | + | |
3148 | 3170 | | |
3149 | 3171 | | |
3150 | 3172 | | |
| |||
3164 | 3186 | | |
3165 | 3187 | | |
3166 | 3188 | | |
| 3189 | + | |
| 3190 | + | |
3167 | 3191 | | |
3168 | 3192 | | |
3169 | 3193 | | |
| |||
3180 | 3204 | | |
3181 | 3205 | | |
3182 | 3206 | | |
| 3207 | + | |
| 3208 | + | |
3183 | 3209 | | |
3184 | 3210 | | |
3185 | 3211 | | |
| |||
0 commit comments