Commit ded58aa
committed
audio: copier: Refactor deep copy of copier config
Code for copying copier_data is ambiguous. A comment suggests that the deep
copy (data structure + variable-length array) is not needed but the copy of
variable-length array is performed afterwards. This changet rectifies this by
placing ipc4_copier_module_cfg at the end of copier_data structure as it
contains a variable-length array. This enables single memory allocation and
single, clean 1:1 copy for the complete copier_data with the variable-length
addition.
Signed-off-by: Wojciech Jablonski <wojciech.jablonski@intel.com>1 parent 9802b40 commit ded58aa
File tree
6 files changed
+24
-61
lines changed- src
- audio/copier
- ipc/ipc4
- zephyr/lib
6 files changed
+24
-61
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
139 | | - | |
140 | | - | |
| 139 | + | |
| 140 | + | |
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | 144 | | |
145 | | - | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
146 | 152 | | |
147 | 153 | | |
148 | 154 | | |
149 | 155 | | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | 156 | | |
160 | | - | |
161 | | - | |
162 | | - | |
163 | | - | |
164 | | - | |
165 | | - | |
166 | | - | |
167 | | - | |
168 | | - | |
169 | | - | |
170 | | - | |
171 | | - | |
172 | | - | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
181 | 160 | | |
182 | 161 | | |
183 | 162 | | |
| |||
257 | 236 | | |
258 | 237 | | |
259 | 238 | | |
260 | | - | |
261 | | - | |
262 | 239 | | |
263 | 240 | | |
264 | 241 | | |
| |||
289 | 266 | | |
290 | 267 | | |
291 | 268 | | |
292 | | - | |
293 | | - | |
294 | 269 | | |
295 | 270 | | |
296 | 271 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
241 | 241 | | |
242 | 242 | | |
243 | 243 | | |
244 | | - | |
245 | | - | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | 244 | | |
252 | 245 | | |
253 | 246 | | |
| |||
277 | 270 | | |
278 | 271 | | |
279 | 272 | | |
| 273 | + | |
| 274 | + | |
280 | 275 | | |
281 | 276 | | |
282 | 277 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
296 | 296 | | |
297 | 297 | | |
298 | 298 | | |
299 | | - | |
| 299 | + | |
300 | 300 | | |
301 | 301 | | |
302 | 302 | | |
| |||
315 | 315 | | |
316 | 316 | | |
317 | 317 | | |
318 | | - | |
319 | | - | |
| 318 | + | |
| 319 | + | |
320 | 320 | | |
321 | 321 | | |
322 | 322 | | |
323 | 323 | | |
324 | 324 | | |
325 | 325 | | |
326 | 326 | | |
327 | | - | |
| 327 | + | |
328 | 328 | | |
329 | 329 | | |
330 | 330 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
34 | 34 | | |
35 | 35 | | |
36 | 36 | | |
37 | | - | |
38 | | - | |
39 | | - | |
40 | | - | |
41 | | - | |
42 | | - | |
| 37 | + | |
| 38 | + | |
43 | 39 | | |
44 | 40 | | |
45 | 41 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
91 | 91 | | |
92 | 92 | | |
93 | 93 | | |
94 | | - | |
95 | | - | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | 94 | | |
100 | | - | |
| 95 | + | |
| 96 | + | |
101 | 97 | | |
102 | 98 | | |
103 | 99 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
122 | 122 | | |
123 | 123 | | |
124 | 124 | | |
125 | | - | |
| 125 | + | |
| 126 | + | |
126 | 127 | | |
127 | 128 | | |
128 | 129 | | |
| |||
0 commit comments