Commit c351193
module_adapter: ipc4: validate pin counts against IPC4 maximum
Reject IPC4 module init payloads where nb_input_pins or nb_output_pins
exceed the protocol maximum (IPC4_MAX_SRC_QUEUE / IPC4_MAX_DST_QUEUE = 8).
The existing cfgsz equality check ensures the immediate pointer
arithmetic is in-bounds, but it does not prevent unsupported pin counts
from being stored in dst->nb_input_pins / dst->nb_output_pins and used
by downstream module code. Add explicit upper-bound validation before
computing pinsz, matching the IPC4 ABI contract advertised via
IPC4_MAX_MODULE_PIN_COUNT_FW_CFG.
Signed-off-by: Adrian Bonislawski <adrian.bonislawski@intel.com>1 parent 818713d commit c351193
1 file changed
Lines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
24 | 25 | | |
25 | 26 | | |
26 | 27 | | |
| |||
162 | 163 | | |
163 | 164 | | |
164 | 165 | | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
165 | 169 | | |
166 | 170 | | |
167 | 171 | | |
| |||
0 commit comments