Adjust the SDU size based on the number of locations/channels that is being requested. --- client/player.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/client/player.c b/client/player.c index ab33bfc46..7856be3b5 100644 --- a/client/player.c +++ b/client/player.c @@ -3574,6 +3574,7 @@ static void config_endpoint_channel_location(const char *input, void *user_data) struct endpoint_config *cfg = user_data; char *endptr = NULL; uint32_t location; + uint8_t channels = 1; if (!strcasecmp(input, "n") || !strcasecmp(input, "no")) goto add_meta; @@ -3590,6 +3591,13 @@ static void config_endpoint_channel_location(const char *input, void *user_data) iov_append_ltv(&cfg->caps, LC3_CONFIG_CHAN_ALLOC_LEN, LC3_CONFIG_CHAN_ALLOC, &location); + /* Adjust the SDU size based on the number of + * locations/channels that is being requested. + */ + channels = __builtin_popcount(location); + if (channels > 1) + cfg->qos.bcast.io_qos.sdu *= channels; + add_meta: /* Add metadata */ bt_shell_prompt_input(cfg->ep->path, "Enter Metadata (value/no):", -- 2.39.2