From: Luiz Augusto von Dentz <[email protected]>
This adds the QoS preset definitions as per BAP specification.
---
src/shared/lc3.h | 153 +++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 153 insertions(+)
diff --git a/src/shared/lc3.h b/src/shared/lc3.h
index ae193f9e2fa7..e6b043699bc1 100644
--- a/src/shared/lc3.h
+++ b/src/shared/lc3.h
@@ -155,3 +155,156 @@
#define LC3_CONFIG_48_6 \
LC3_CONFIG_48(LC3_CONFIG_DURATION_10, 155u)
+
+#define LC3_QOS_UNFRAMED 0x00
+#define LC3_QOS_FRAMED 0x01
+
+#define LC3_QOS_UCAST(_frame, _pd, _t_lat, _interval, _lat, _sdu, _rtn) \
+{ \
+ .ucast.cig_id = 0x00, \
+ .ucast.cis_id = 0x00, \
+ .ucast.delay = _pd, \
+ .ucast.target_latency = _t_lat, \
+ .ucast.io_qos.interval = _interval, \
+ .ucast.io_qos.latency = _lat, \
+ .ucast.io_qos.sdu = _sdu, \
+ .ucast.io_qos.phy = BT_BAP_CONFIG_PHY_2M, \
+ .ucast.io_qos.rtn = _rtn, \
+}
+
+#define LC3_QOS_UCAST_7_5_UNFRAMED(_pd, _t_lat, _lat, _sdu, _rtn) \
+ LC3_QOS_UCAST(LC3_QOS_UNFRAMED, _pd, _t_lat, 7500u, _lat, _sdu, _rtn)
+
+#define LC3_QOS_UCAST_10_UNFRAMED(_pd, _t_lat, _lat, _sdu, _rtn) \
+ LC3_QOS_UCAST(LC3_QOS_UNFRAMED, _pd, _t_lat, 10000u, _lat, _sdu, _rtn)
+
+#define LC3_QOS_UCAST_FRAMED(_pd, _t_lat, _interval, _lat, _sdu, _rtn) \
+ LC3_QOS_UCAST(LC3_QOS_FRAMED, _pd, _t_lat, _interval, _lat, _sdu, _rtn)
+
+#define LC3_QOS_8_1_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8u, 26u, 2u)
+
+#define LC3_QOS_8_1_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 26u, 13u)
+
+#define LC3_QOS_8_2_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10u, 30u, 2u)
+
+#define LC3_QOS_8_2_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 95u, 30u, 13u)
+
+#define LC3_QOS_16_1_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8u, 30u, 2u)
+
+#define LC3_QOS_16_1_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 30u, 13u)
+
+#define LC3_QOS_16_2_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10u, 40u, 2u)
+
+#define LC3_QOS_16_2_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 95u, 40u, 13u)
+
+#define LC3_QOS_24_1_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8u, 45u, 2u)
+
+#define LC3_QOS_24_1_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 45u, 13u)
+
+#define LC3_QOS_24_2_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10u, 60u, 2u)
+
+#define LC3_QOS_24_2_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 95u, 60u, 13u)
+
+#define LC3_QOS_32_1_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8u, 60u, 2u)
+
+#define LC3_QOS_32_1_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 60u, 13u)
+
+#define LC3_QOS_32_2_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10u, 80u, 2u)
+
+#define LC3_QOS_32_2_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 95u, 80u, 13u)
+
+#define LC3_QOS_44_1_1 \
+ LC3_QOS_UCAST_FRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8163u, 24u, 98u, 5u)
+
+#define LC3_QOS_44_1_2 \
+ LC3_QOS_UCAST_FRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 8163u, 80u, 98u, 13u)
+
+#define LC3_QOS_44_2_1 \
+ LC3_QOS_UCAST_FRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10884u, 31u, 130u, 5u)
+
+#define LC3_QOS_44_2_2 \
+ LC3_QOS_UCAST_FRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 10884u, 85u, 130u, 13u)
+
+#define LC3_QOS_48_1_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 15u, 75u, 5u)
+
+#define LC3_QOS_48_1_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 75u, 13u)
+
+#define LC3_QOS_48_2_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 20u, 100u, 5u)
+
+#define LC3_QOS_48_2_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 95u, 100u, 13u)
+
+#define LC3_QOS_48_3_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 15u, 90u, 5u)
+
+#define LC3_QOS_48_3_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 90u, 13u)
+
+#define LC3_QOS_48_4_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 20u, 120u, 5u)
+
+#define LC3_QOS_48_4_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 100u, 120u, 13u)
+
+#define LC3_QOS_48_5_1 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 15u, 117u, 5u)
+
+#define LC3_QOS_48_5_2 \
+ LC3_QOS_UCAST_7_5_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 75u, 117u, 13u)
+
+#define LC3_QOS_48_6_1 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 20u, 155u, 5u)
+
+#define LC3_QOS_48_6_2 \
+ LC3_QOS_UCAST_10_UNFRAMED(40000u, BT_BAP_CONFIG_LATENCY_BALANCED, \
+ 100u, 155u, 13u)
--
2.43.0
From: Luiz Augusto von Dentz <[email protected]>
4.8.3 Unicast Client Initiates Config QoS – LC3
(Page 43)
Test Purpose:
Verify that a Unicast Client IUT can initiate a Config QoS operation for the
LC3 codec.
Pass verdict:
The IUT successfully writes to the ASE Control Point characteristic with the
opcode set to 0x02 (Config QoS) and the specified parameters.
Test Summary
------------
BAP/UCL/SCC/BV-035-C [UCL SRC Config QoS, LC3 8_1_1] Passed
BAP/UCL/SCC/BV-036-C [UCL SRC Config QoS, LC3 8_2_1] Passed
BAP/UCL/SCC/BV-037-C [UCL SRC Config QoS, LC3 16_1_1] Passed
BAP/UCL/SCC/BV-038-C [UCL SRC Config QoS, LC3 16_2_1] Passed
BAP/UCL/SCC/BV-039-C [UCL SRC Config QoS, LC3 24_1_1] Passed
BAP/UCL/SCC/BV-040-C [UCL SRC Config QoS, LC3 24_2_1] Passed
BAP/UCL/SCC/BV-041-C [UCL SRC Config QoS, LC3 32_1_1] Passed
BAP/UCL/SCC/BV-042-C [UCL SRC Config QoS, LC3 32_2_1] Passed
BAP/UCL/SCC/BV-043-C [UCL SRC Config QoS, LC3 44.1_1_1] Passed
BAP/UCL/SCC/BV-044-C [UCL SRC Config QoS, LC3 44.1_2_1] Passed
BAP/UCL/SCC/BV-045-C [UCL SRC Config QoS, LC3 48_1_1] Passed
BAP/UCL/SCC/BV-046-C [UCL SRC Config QoS, LC3 48_2_1] Passed
BAP/UCL/SCC/BV-047-C [UCL SRC Config QoS, LC3 48_3_1] Passed
BAP/UCL/SCC/BV-048-C [UCL SRC Config QoS, LC3 48_4_1] Passed
BAP/UCL/SCC/BV-049-C [UCL SRC Config QoS, LC3 48_5_1] Passed
BAP/UCL/SCC/BV-050-C [UCL SRC Config QoS, LC3 48_6_1] Passed
BAP/UCL/SCC/BV-051-C [UCL SNK Config QoS, LC3 8_1_1] Passed
BAP/UCL/SCC/BV-052-C [UCL SNK Config QoS, LC3 8_2_1] Passed
BAP/UCL/SCC/BV-053-C [UCL SNK Config QoS, LC3 16_1_1] Passed
BAP/UCL/SCC/BV-054-C [UCL SNK Config QoS, LC3 16_2_1] Passed
BAP/UCL/SCC/BV-055-C [UCL SNK Config QoS, LC3 24_1_1] Passed
BAP/UCL/SCC/BV-056-C [UCL SNK Config QoS, LC3 24_2_1] Passed
BAP/UCL/SCC/BV-057-C [UCL SNK Config QoS, LC3 32_1_1] Passed
BAP/UCL/SCC/BV-058-C [UCL SNK Config QoS, LC3 32_2_1] Passed
BAP/UCL/SCC/BV-059-C [UCL SNK Config QoS, LC3 44.1_1_1] Passed
BAP/UCL/SCC/BV-060-C [UCL SNK Config QoS, LC3 44.1_2_1] Passed
BAP/UCL/SCC/BV-061-C [UCL SNK Config QoS, LC3 48_1_1] Passed
BAP/UCL/SCC/BV-062-C [UCL SNK Config QoS, LC3 48_2_1] Passed
BAP/UCL/SCC/BV-063-C [UCL SNK Config QoS, LC3 48_3_1] Passed
BAP/UCL/SCC/BV-064-C [UCL SNK Config QoS, LC3 48_4_1] Passed
BAP/UCL/SCC/BV-065-C [UCL SNK Config QoS, LC3 48_5_1] Passed
BAP/UCL/SCC/BV-066-C [UCL SNK Config QoS, LC3 48_6_1] Passed
BAP/UCL/SCC/BV-067-C [UCL SRC Config QoS, LC3 8_1_2] Passed
BAP/UCL/SCC/BV-068-C [UCL SRC Config QoS, LC3 8_2_2] Passed
BAP/UCL/SCC/BV-069-C [UCL SRC Config QoS, LC3 16_1_2] Passed
BAP/UCL/SCC/BV-070-C [UCL SRC Config QoS, LC3 16_2_2] Passed
BAP/UCL/SCC/BV-071-C [UCL SRC Config QoS, LC3 24_1_2] Passed
BAP/UCL/SCC/BV-072-C [UCL SRC Config QoS, LC3 24_2_2] Passed
BAP/UCL/SCC/BV-073-C [UCL SRC Config QoS, LC3 32_1_2] Passed
BAP/UCL/SCC/BV-074-C [UCL SRC Config QoS, LC3 32_2_2] Passed
BAP/UCL/SCC/BV-075-C [UCL SRC Config QoS, LC3 44.1_1_2] Passed
BAP/UCL/SCC/BV-076-C [UCL SRC Config QoS, LC3 44.1_2_2] Passed
BAP/UCL/SCC/BV-077-C [UCL SRC Config QoS, LC3 48_1_2] Passed
BAP/UCL/SCC/BV-078-C [UCL SRC Config QoS, LC3 48_2_2] Passed
BAP/UCL/SCC/BV-079-C [UCL SRC Config QoS, LC3 48_3_2] Passed
BAP/UCL/SCC/BV-080-C [UCL SRC Config QoS, LC3 48_4_2] Passed
BAP/UCL/SCC/BV-081-C [UCL SRC Config QoS, LC3 48_5_2] Passed
BAP/UCL/SCC/BV-082-C [UCL SRC Config QoS, LC3 48_6_2] Passed
BAP/UCL/SCC/BV-083-C [UCL SNK Config QoS, LC3 8_1_2] Passed
BAP/UCL/SCC/BV-084-C [UCL SNK Config QoS, LC3 8_2_2] Passed
BAP/UCL/SCC/BV-085-C [UCL SNK Config QoS, LC3 16_1_2] Passed
BAP/UCL/SCC/BV-086-C [UCL SNK Config QoS, LC3 16_2_2] Passed
BAP/UCL/SCC/BV-087-C [UCL SNK Config QoS, LC3 24_1_2] Passed
BAP/UCL/SCC/BV-088-C [UCL SNK Config QoS, LC3 24_2_2] Passed
BAP/UCL/SCC/BV-089-C [UCL SNK Config QoS, LC3 32_1_2] Passed
BAP/UCL/SCC/BV-090-C [UCL SNK Config QoS, LC3 32_2_2] Passed
BAP/UCL/SCC/BV-091-C [UCL SNK Config QoS, LC3 44.1_1_2] Passed
BAP/UCL/SCC/BV-092-C [UCL SNK Config QoS, LC3 44.1_2_2] Passed
BAP/UCL/SCC/BV-093-C [UCL SNK Config QoS, LC3 48_1_2] Passed
BAP/UCL/SCC/BV-094-C [UCL SNK Config QoS, LC3 48_2_2] Passed
BAP/UCL/SCC/BV-095-C [UCL SNK Config QoS, LC3 48_3_2] Passed
BAP/UCL/SCC/BV-096-C [UCL SNK Config QoS, LC3 48_4_2] Passed
BAP/UCL/SCC/BV-097-C [UCL SNK Config QoS, LC3 48_5_2] Passed
BAP/UCL/SCC/BV-098-C [UCL SNK Config QoS, LC3 48_6_2] Passed
Total: 64, Passed: 64 (100.0%), Failed: 0, Not Run: 0
---
unit/test-bap.c | 964 +++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 963 insertions(+), 1 deletion(-)
diff --git a/unit/test-bap.c b/unit/test-bap.c
index adade07dbe9e..303388e35c14 100644
--- a/unit/test-bap.c
+++ b/unit/test-bap.c
@@ -39,6 +39,7 @@ struct test_config {
bool snk;
bool src;
bool vs;
+ uint8_t state;
};
struct test_data {
@@ -334,7 +335,7 @@ static void test_complete_cb(const void *user_data)
tester_test_passed();
}
-static void bap_config(struct bt_bap_stream *stream,
+static void bap_qos(struct bt_bap_stream *stream,
uint8_t code, uint8_t reason,
void *user_data)
{
@@ -342,6 +343,26 @@ static void bap_config(struct bt_bap_stream *stream,
tester_test_failed();
}
+static void bap_config(struct bt_bap_stream *stream,
+ uint8_t code, uint8_t reason,
+ void *user_data)
+{
+ struct test_data *data = user_data;
+
+ if (code) {
+ tester_test_failed();
+ return;
+ }
+
+ if (data->cfg->state > BT_BAP_STREAM_STATE_CONFIG) {
+ unsigned int qos_id;
+
+ qos_id = bt_bap_stream_qos(data->stream, &data->cfg->qos,
+ bap_qos, data);
+ g_assert(qos_id);
+ }
+}
+
static bool pac_found(struct bt_bap_pac *lpac, struct bt_bap_pac *rpac,
void *user_data)
{
@@ -1185,10 +1206,951 @@ static void test_scc_cc_vs(void)
test_client, &cfg_src_vs, SCC_SRC_VS);
}
+static struct test_config cfg_snk_8_1_1 = {
+ .cc = LC3_CONFIG_8_1,
+ .qos = LC3_QOS_8_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_8_2_1 = {
+ .cc = LC3_CONFIG_8_2,
+ .qos = LC3_QOS_8_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_16_1_1 = {
+ .cc = LC3_CONFIG_16_1,
+ .qos = LC3_QOS_16_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_16_2_1 = {
+ .cc = LC3_CONFIG_16_2,
+ .qos = LC3_QOS_16_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_24_1_1 = {
+ .cc = LC3_CONFIG_24_1,
+ .qos = LC3_QOS_24_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_24_2_1 = {
+ .cc = LC3_CONFIG_24_2,
+ .qos = LC3_QOS_24_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_32_1_1 = {
+ .cc = LC3_CONFIG_32_1,
+ .qos = LC3_QOS_32_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_32_2_1 = {
+ .cc = LC3_CONFIG_32_2,
+ .qos = LC3_QOS_32_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_44_1_1 = {
+ .cc = LC3_CONFIG_44_1,
+ .qos = LC3_QOS_44_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_44_2_1 = {
+ .cc = LC3_CONFIG_44_2,
+ .qos = LC3_QOS_44_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_1_1 = {
+ .cc = LC3_CONFIG_48_1,
+ .qos = LC3_QOS_48_1_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_2_1 = {
+ .cc = LC3_CONFIG_48_2,
+ .qos = LC3_QOS_48_2_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_3_1 = {
+ .cc = LC3_CONFIG_48_3,
+ .qos = LC3_QOS_48_3_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_4_1 = {
+ .cc = LC3_CONFIG_48_4,
+ .qos = LC3_QOS_48_4_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_5_1 = {
+ .cc = LC3_CONFIG_48_5,
+ .qos = LC3_QOS_48_5_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_6_1 = {
+ .cc = LC3_CONFIG_48_6,
+ .qos = LC3_QOS_48_6_1,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+/* ATT: Write Command (0x52) len 23
+ * Handle: 0x0022
+ * Data: 02010000_qos
+ * ATT: Handle Value Notification (0x1b) len 7
+ * Handle: 0x0022
+ * Data: 0201010000
+ * ATT: Handle Value Notification (0x1b) len 37
+ * Handle: 0x0016
+ * Data: 01010102010a00204e00409c00204e00409c00_qos
+ */
+#define QOS_SNK(_qos...) \
+ IOV_DATA(0x52, 0x22, 0x00, 0x02, 0x01, 0x01, 0x00, 0x00, _qos), \
+ IOV_DATA(0x1b, 0x22, 0x00, 0x02, 0x01, 0x01, 0x00, 0x00), \
+ IOV_NULL, \
+ IOV_DATA(0x1b, 0x16, 0x00, 0x01, 0x02, 0x00, 0x00, _qos)
+
+#define SCC_SNK_8_1_1 \
+ SCC_SNK_8_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1a, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_8_2_1 \
+ SCC_SNK_8_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_16_1_1 \
+ SCC_SNK_16_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_16_2_1 \
+ SCC_SNK_16_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x28, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_24_1_1 \
+ SCC_SNK_24_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x2d, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_24_2_1 \
+ SCC_SNK_24_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_32_1_1 \
+ SCC_SNK_32_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_32_2_1 \
+ SCC_SNK_32_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x50, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_44_1_1 \
+ SCC_SNK_44_1, \
+ QOS_SNK(0xe3, 0x1f, 0x00, 0x00, 0x02, 0x62, 0x00, 0x05, 0x18, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_44_2_1 \
+ SCC_SNK_44_2, \
+ QOS_SNK(0x84, 0x2a, 0x00, 0x00, 0x02, 0x82, 0x00, 0x05, 0x1f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_1_1 \
+ SCC_SNK_48_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x4b, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_2_1 \
+ SCC_SNK_48_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x64, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_3_1 \
+ SCC_SNK_48_3, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x5a, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_4_1 \
+ SCC_SNK_48_4, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x78, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_5_1 \
+ SCC_SNK_48_5, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x75, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_6_1 \
+ SCC_SNK_48_6, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x9b, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+static struct test_config cfg_src_8_1_1 = {
+ .cc = LC3_CONFIG_8_1,
+ .qos = LC3_QOS_8_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_8_2_1 = {
+ .cc = LC3_CONFIG_8_2,
+ .qos = LC3_QOS_8_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_16_1_1 = {
+ .cc = LC3_CONFIG_16_1,
+ .qos = LC3_QOS_16_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_16_2_1 = {
+ .cc = LC3_CONFIG_16_2,
+ .qos = LC3_QOS_16_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_24_1_1 = {
+ .cc = LC3_CONFIG_24_1,
+ .qos = LC3_QOS_24_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_24_2_1 = {
+ .cc = LC3_CONFIG_24_2,
+ .qos = LC3_QOS_24_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_32_1_1 = {
+ .cc = LC3_CONFIG_32_1,
+ .qos = LC3_QOS_32_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_32_2_1 = {
+ .cc = LC3_CONFIG_32_2,
+ .qos = LC3_QOS_32_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_44_1_1 = {
+ .cc = LC3_CONFIG_44_1,
+ .qos = LC3_QOS_44_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_44_2_1 = {
+ .cc = LC3_CONFIG_44_2,
+ .qos = LC3_QOS_44_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_1_1 = {
+ .cc = LC3_CONFIG_48_1,
+ .qos = LC3_QOS_48_1_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_2_1 = {
+ .cc = LC3_CONFIG_48_2,
+ .qos = LC3_QOS_48_2_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_3_1 = {
+ .cc = LC3_CONFIG_48_3,
+ .qos = LC3_QOS_48_3_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_4_1 = {
+ .cc = LC3_CONFIG_48_4,
+ .qos = LC3_QOS_48_4_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_5_1 = {
+ .cc = LC3_CONFIG_48_5,
+ .qos = LC3_QOS_48_5_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_6_1 = {
+ .cc = LC3_CONFIG_48_6,
+ .qos = LC3_QOS_48_6_1,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+/* ATT: Write Command (0x52) len 23
+ * Handle: 0x0022
+ * Data: 02030000_qos
+ * ATT: Handle Value Notification (0x1b) len 7
+ * Handle: 0x0022
+ * Data: 0201030000
+ * ATT: Handle Value Notification (0x1b) len 37
+ * Handle: 0x001c
+ * Data: 03010102010a00204e00409c00204e00409c00_qos
+ */
+#define QOS_SRC(_qos...) \
+ IOV_DATA(0x52, 0x22, 0x00, 0x02, 0x01, 0x03, 0x00, 0x00, _qos), \
+ IOV_DATA(0x1b, 0x22, 0x00, 0x02, 0x01, 0x01, 0x00, 0x00), \
+ IOV_NULL, \
+ IOV_DATA(0x1b, 0x1c, 0x00, 0x03, 0x02, 0x00, 0x00, _qos)
+
+#define SCC_SRC_8_1_1 \
+ SCC_SRC_8_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1a, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_8_2_1 \
+ SCC_SRC_8_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_16_1_1 \
+ SCC_SRC_16_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_16_2_1 \
+ SCC_SRC_16_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x28, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_24_1_1 \
+ SCC_SRC_24_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x2d, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_24_2_1 \
+ SCC_SRC_24_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_32_1_1 \
+ SCC_SRC_32_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x02, 0x08, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_32_2_1 \
+ SCC_SRC_32_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x50, 0x00, 0x02, 0x0a, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_44_1_1 \
+ SCC_SRC_44_1, \
+ QOS_SRC(0xe3, 0x1f, 0x00, 0x00, 0x02, 0x62, 0x00, 0x05, 0x18, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_44_2_1 \
+ SCC_SRC_44_2, \
+ QOS_SRC(0x84, 0x2a, 0x00, 0x00, 0x02, 0x82, 0x00, 0x05, 0x1f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_1_1 \
+ SCC_SRC_48_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x4b, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_2_1 \
+ SCC_SRC_48_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x64, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_3_1 \
+ SCC_SRC_48_3, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x5a, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_4_1 \
+ SCC_SRC_48_4, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x78, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_5_1 \
+ SCC_SRC_48_5, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x75, 0x00, 0x05, 0x0f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_6_1 \
+ SCC_SRC_48_6, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x9b, 0x00, 0x05, 0x14, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+static struct test_config cfg_snk_8_1_2 = {
+ .cc = LC3_CONFIG_8_1,
+ .qos = LC3_QOS_8_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_8_2_2 = {
+ .cc = LC3_CONFIG_8_2,
+ .qos = LC3_QOS_8_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_16_1_2 = {
+ .cc = LC3_CONFIG_16_1,
+ .qos = LC3_QOS_16_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_16_2_2 = {
+ .cc = LC3_CONFIG_16_2,
+ .qos = LC3_QOS_16_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_24_1_2 = {
+ .cc = LC3_CONFIG_24_1,
+ .qos = LC3_QOS_24_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_24_2_2 = {
+ .cc = LC3_CONFIG_24_2,
+ .qos = LC3_QOS_24_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_32_1_2 = {
+ .cc = LC3_CONFIG_32_1,
+ .qos = LC3_QOS_32_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_32_2_2 = {
+ .cc = LC3_CONFIG_32_2,
+ .qos = LC3_QOS_32_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_44_1_2 = {
+ .cc = LC3_CONFIG_44_1,
+ .qos = LC3_QOS_44_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_44_2_2 = {
+ .cc = LC3_CONFIG_44_2,
+ .qos = LC3_QOS_44_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_1_2 = {
+ .cc = LC3_CONFIG_48_1,
+ .qos = LC3_QOS_48_1_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_2_2 = {
+ .cc = LC3_CONFIG_48_2,
+ .qos = LC3_QOS_48_2_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_3_2 = {
+ .cc = LC3_CONFIG_48_3,
+ .qos = LC3_QOS_48_3_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_4_2 = {
+ .cc = LC3_CONFIG_48_4,
+ .qos = LC3_QOS_48_4_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_5_2 = {
+ .cc = LC3_CONFIG_48_5,
+ .qos = LC3_QOS_48_5_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_snk_48_6_2 = {
+ .cc = LC3_CONFIG_48_6,
+ .qos = LC3_QOS_48_6_2,
+ .snk = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+#define SCC_SNK_8_1_2 \
+ SCC_SNK_8_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1a, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_8_2_2 \
+ SCC_SNK_8_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_16_1_2 \
+ SCC_SNK_16_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_16_2_2 \
+ SCC_SNK_16_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x28, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_24_1_2 \
+ SCC_SNK_24_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x2d, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_24_2_2 \
+ SCC_SNK_24_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_32_1_2 \
+ SCC_SNK_32_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_32_2_2 \
+ SCC_SNK_32_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x50, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_44_1_2 \
+ SCC_SNK_44_1, \
+ QOS_SNK(0xe3, 0x1f, 0x00, 0x00, 0x02, 0x62, 0x00, 0x0d, 0x50, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_44_2_2 \
+ SCC_SNK_44_2, \
+ QOS_SNK(0x84, 0x2a, 0x00, 0x00, 0x02, 0x82, 0x00, 0x0d, 0x55, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_1_2 \
+ SCC_SNK_48_1, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x4b, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_2_2 \
+ SCC_SNK_48_2, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x64, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_3_2 \
+ SCC_SNK_48_3, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x5a, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_4_2 \
+ SCC_SNK_48_4, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x78, 0x00, 0x0d, 0x64, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_5_2 \
+ SCC_SNK_48_5, \
+ QOS_SNK(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x75, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SNK_48_6_2 \
+ SCC_SNK_48_6, \
+ QOS_SNK(0x10, 0x27, 0x00, 0x00, 0x02, 0x9b, 0x00, 0x0d, 0x64, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+static struct test_config cfg_src_8_1_2 = {
+ .cc = LC3_CONFIG_8_1,
+ .qos = LC3_QOS_8_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_8_2_2 = {
+ .cc = LC3_CONFIG_8_2,
+ .qos = LC3_QOS_8_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_16_1_2 = {
+ .cc = LC3_CONFIG_16_1,
+ .qos = LC3_QOS_16_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_16_2_2 = {
+ .cc = LC3_CONFIG_16_2,
+ .qos = LC3_QOS_16_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_24_1_2 = {
+ .cc = LC3_CONFIG_24_1,
+ .qos = LC3_QOS_24_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_24_2_2 = {
+ .cc = LC3_CONFIG_24_2,
+ .qos = LC3_QOS_24_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_32_1_2 = {
+ .cc = LC3_CONFIG_32_1,
+ .qos = LC3_QOS_32_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_32_2_2 = {
+ .cc = LC3_CONFIG_32_2,
+ .qos = LC3_QOS_32_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_44_1_2 = {
+ .cc = LC3_CONFIG_44_1,
+ .qos = LC3_QOS_44_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_44_2_2 = {
+ .cc = LC3_CONFIG_44_2,
+ .qos = LC3_QOS_44_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_1_2 = {
+ .cc = LC3_CONFIG_48_1,
+ .qos = LC3_QOS_48_1_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_2_2 = {
+ .cc = LC3_CONFIG_48_2,
+ .qos = LC3_QOS_48_2_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_3_2 = {
+ .cc = LC3_CONFIG_48_3,
+ .qos = LC3_QOS_48_3_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_4_2 = {
+ .cc = LC3_CONFIG_48_4,
+ .qos = LC3_QOS_48_4_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_5_2 = {
+ .cc = LC3_CONFIG_48_5,
+ .qos = LC3_QOS_48_5_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+static struct test_config cfg_src_48_6_2 = {
+ .cc = LC3_CONFIG_48_6,
+ .qos = LC3_QOS_48_6_2,
+ .src = true,
+ .state = BT_BAP_STREAM_STATE_QOS,
+};
+
+#define SCC_SRC_8_1_2 \
+ SCC_SRC_8_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1a, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_8_2_2 \
+ SCC_SRC_8_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_16_1_2 \
+ SCC_SRC_16_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x1e, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_16_2_2 \
+ SCC_SRC_16_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x28, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_24_1_2 \
+ SCC_SRC_24_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x2d, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_24_2_2 \
+ SCC_SRC_24_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_32_1_2 \
+ SCC_SRC_32_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x3c, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_32_2_2 \
+ SCC_SRC_32_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x50, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_44_1_2 \
+ SCC_SRC_44_1, \
+ QOS_SRC(0xe3, 0x1f, 0x00, 0x00, 0x02, 0x62, 0x00, 0x0d, 0x50, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_44_2_2 \
+ SCC_SRC_44_2, \
+ QOS_SRC(0x84, 0x2a, 0x00, 0x00, 0x02, 0x82, 0x00, 0x0d, 0x55, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_1_2 \
+ SCC_SRC_48_1, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x4b, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_2_2 \
+ SCC_SRC_48_2, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x64, 0x00, 0x0d, 0x5f, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_3_2 \
+ SCC_SRC_48_3, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x5a, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_4_2 \
+ SCC_SRC_48_4, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x78, 0x00, 0x0d, 0x64, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_5_2 \
+ SCC_SRC_48_5, \
+ QOS_SRC(0x4c, 0x1d, 0x00, 0x00, 0x02, 0x75, 0x00, 0x0d, 0x4b, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+#define SCC_SRC_48_6_2 \
+ SCC_SRC_48_6, \
+ QOS_SRC(0x10, 0x27, 0x00, 0x00, 0x02, 0x9b, 0x00, 0x0d, 0x64, 0x00, \
+ 0x40, 0x9c, 0x00)
+
+/* Test Purpose:
+ * Verify that a Unicast Client IUT can initiate a Config QoS operation for the
+ * LC3 codec.
+ *
+ * Pass verdict:
+ * The IUT successfully writes to the ASE Control Point characteristic with the
+ * opcode set to 0x02 (Config QoS) and the specified parameters.
+ */
+static void test_scc_qos_lc3(void)
+{
+ define_test("BAP/UCL/SCC/BV-035-C [UCL SRC Config QoS, LC3 8_1_1]",
+ test_client, &cfg_snk_8_1_1, SCC_SNK_8_1_1);
+ define_test("BAP/UCL/SCC/BV-036-C [UCL SRC Config QoS, LC3 8_2_1]",
+ test_client, &cfg_snk_8_2_1, SCC_SNK_8_2_1);
+ define_test("BAP/UCL/SCC/BV-037-C [UCL SRC Config QoS, LC3 16_1_1]",
+ test_client, &cfg_snk_16_1_1, SCC_SNK_16_1_1);
+ define_test("BAP/UCL/SCC/BV-038-C [UCL SRC Config QoS, LC3 16_2_1]",
+ test_client, &cfg_snk_16_2_1, SCC_SNK_16_2_1);
+ define_test("BAP/UCL/SCC/BV-039-C [UCL SRC Config QoS, LC3 24_1_1]",
+ test_client, &cfg_snk_24_1_1, SCC_SNK_24_1_1);
+ define_test("BAP/UCL/SCC/BV-040-C [UCL SRC Config QoS, LC3 24_2_1]",
+ test_client, &cfg_snk_24_2_1, SCC_SNK_24_2_1);
+ define_test("BAP/UCL/SCC/BV-041-C [UCL SRC Config QoS, LC3 32_1_1]",
+ test_client, &cfg_snk_32_1_1, SCC_SNK_32_1_1);
+ define_test("BAP/UCL/SCC/BV-042-C [UCL SRC Config QoS, LC3 32_2_1]",
+ test_client, &cfg_snk_32_2_1, SCC_SNK_32_2_1);
+ define_test("BAP/UCL/SCC/BV-043-C [UCL SRC Config QoS, LC3 44.1_1_1]",
+ test_client, &cfg_snk_44_1_1, SCC_SNK_44_1_1);
+ define_test("BAP/UCL/SCC/BV-044-C [UCL SRC Config QoS, LC3 44.1_2_1]",
+ test_client, &cfg_snk_44_2_1, SCC_SNK_44_2_1);
+ define_test("BAP/UCL/SCC/BV-045-C [UCL SRC Config QoS, LC3 48_1_1]",
+ test_client, &cfg_snk_48_1_1, SCC_SNK_48_1_1);
+ define_test("BAP/UCL/SCC/BV-046-C [UCL SRC Config QoS, LC3 48_2_1]",
+ test_client, &cfg_snk_48_2_1, SCC_SNK_48_2_1);
+ define_test("BAP/UCL/SCC/BV-047-C [UCL SRC Config QoS, LC3 48_3_1]",
+ test_client, &cfg_snk_48_3_1, SCC_SNK_48_3_1);
+ define_test("BAP/UCL/SCC/BV-048-C [UCL SRC Config QoS, LC3 48_4_1]",
+ test_client, &cfg_snk_48_4_1, SCC_SNK_48_4_1);
+ define_test("BAP/UCL/SCC/BV-049-C [UCL SRC Config QoS, LC3 48_5_1]",
+ test_client, &cfg_snk_48_5_1, SCC_SNK_48_5_1);
+ define_test("BAP/UCL/SCC/BV-050-C [UCL SRC Config QoS, LC3 48_6_1]",
+ test_client, &cfg_snk_48_6_1, SCC_SNK_48_6_1);
+ define_test("BAP/UCL/SCC/BV-051-C [UCL SNK Config QoS, LC3 8_1_1]",
+ test_client, &cfg_src_8_1_1, SCC_SRC_8_1_1);
+ define_test("BAP/UCL/SCC/BV-052-C [UCL SNK Config QoS, LC3 8_2_1]",
+ test_client, &cfg_src_8_2_1, SCC_SRC_8_2_1);
+ define_test("BAP/UCL/SCC/BV-053-C [UCL SNK Config QoS, LC3 16_1_1]",
+ test_client, &cfg_src_16_1_1, SCC_SRC_16_1_1);
+ define_test("BAP/UCL/SCC/BV-054-C [UCL SNK Config QoS, LC3 16_2_1]",
+ test_client, &cfg_src_16_2_1, SCC_SRC_16_2_1);
+ define_test("BAP/UCL/SCC/BV-055-C [UCL SNK Config QoS, LC3 24_1_1]",
+ test_client, &cfg_src_24_1_1, SCC_SRC_24_1_1);
+ define_test("BAP/UCL/SCC/BV-056-C [UCL SNK Config QoS, LC3 24_2_1]",
+ test_client, &cfg_src_24_2_1, SCC_SRC_24_2_1);
+ define_test("BAP/UCL/SCC/BV-057-C [UCL SNK Config QoS, LC3 32_1_1]",
+ test_client, &cfg_src_32_1_1, SCC_SRC_32_1_1);
+ define_test("BAP/UCL/SCC/BV-058-C [UCL SNK Config QoS, LC3 32_2_1]",
+ test_client, &cfg_src_32_2_1, SCC_SRC_32_2_1);
+ define_test("BAP/UCL/SCC/BV-059-C [UCL SNK Config QoS, LC3 44.1_1_1]",
+ test_client, &cfg_src_44_1_1, SCC_SRC_44_1_1);
+ define_test("BAP/UCL/SCC/BV-060-C [UCL SNK Config QoS, LC3 44.1_2_1]",
+ test_client, &cfg_src_44_2_1, SCC_SRC_44_2_1);
+ define_test("BAP/UCL/SCC/BV-061-C [UCL SNK Config QoS, LC3 48_1_1]",
+ test_client, &cfg_src_48_1_1, SCC_SRC_48_1_1);
+ define_test("BAP/UCL/SCC/BV-062-C [UCL SNK Config QoS, LC3 48_2_1]",
+ test_client, &cfg_src_48_2_1, SCC_SRC_48_2_1);
+ define_test("BAP/UCL/SCC/BV-063-C [UCL SNK Config QoS, LC3 48_3_1]",
+ test_client, &cfg_src_48_3_1, SCC_SRC_48_3_1);
+ define_test("BAP/UCL/SCC/BV-064-C [UCL SNK Config QoS, LC3 48_4_1]",
+ test_client, &cfg_src_48_4_1, SCC_SRC_48_4_1);
+ define_test("BAP/UCL/SCC/BV-065-C [UCL SNK Config QoS, LC3 48_5_1]",
+ test_client, &cfg_src_48_5_1, SCC_SRC_48_5_1);
+ define_test("BAP/UCL/SCC/BV-066-C [UCL SNK Config QoS, LC3 48_6_1]",
+ test_client, &cfg_src_48_6_1, SCC_SRC_48_6_1);
+ define_test("BAP/UCL/SCC/BV-067-C [UCL SRC Config QoS, LC3 8_1_2]",
+ test_client, &cfg_snk_8_1_2, SCC_SNK_8_1_2);
+ define_test("BAP/UCL/SCC/BV-068-C [UCL SRC Config QoS, LC3 8_2_2]",
+ test_client, &cfg_snk_8_2_2, SCC_SNK_8_2_2);
+ define_test("BAP/UCL/SCC/BV-069-C [UCL SRC Config QoS, LC3 16_1_2]",
+ test_client, &cfg_snk_16_1_2, SCC_SNK_16_1_2);
+ define_test("BAP/UCL/SCC/BV-070-C [UCL SRC Config QoS, LC3 16_2_2]",
+ test_client, &cfg_snk_16_2_2, SCC_SNK_16_2_2);
+ define_test("BAP/UCL/SCC/BV-071-C [UCL SRC Config QoS, LC3 24_1_2]",
+ test_client, &cfg_snk_24_1_2, SCC_SNK_24_1_2);
+ define_test("BAP/UCL/SCC/BV-072-C [UCL SRC Config QoS, LC3 24_2_2]",
+ test_client, &cfg_snk_24_2_2, SCC_SNK_24_2_2);
+ define_test("BAP/UCL/SCC/BV-073-C [UCL SRC Config QoS, LC3 32_1_2]",
+ test_client, &cfg_snk_32_1_2, SCC_SNK_32_1_2);
+ define_test("BAP/UCL/SCC/BV-074-C [UCL SRC Config QoS, LC3 32_2_2]",
+ test_client, &cfg_snk_32_2_2, SCC_SNK_32_2_2);
+ define_test("BAP/UCL/SCC/BV-075-C [UCL SRC Config QoS, LC3 44.1_1_2]",
+ test_client, &cfg_snk_44_1_2, SCC_SNK_44_1_2);
+ define_test("BAP/UCL/SCC/BV-076-C [UCL SRC Config QoS, LC3 44.1_2_2]",
+ test_client, &cfg_snk_44_2_2, SCC_SNK_44_2_2);
+ define_test("BAP/UCL/SCC/BV-077-C [UCL SRC Config QoS, LC3 48_1_2]",
+ test_client, &cfg_snk_48_1_2, SCC_SNK_48_1_2);
+ define_test("BAP/UCL/SCC/BV-078-C [UCL SRC Config QoS, LC3 48_2_2]",
+ test_client, &cfg_snk_48_2_2, SCC_SNK_48_2_2);
+ define_test("BAP/UCL/SCC/BV-079-C [UCL SRC Config QoS, LC3 48_3_2]",
+ test_client, &cfg_snk_48_3_2, SCC_SNK_48_3_2);
+ define_test("BAP/UCL/SCC/BV-080-C [UCL SRC Config QoS, LC3 48_4_2]",
+ test_client, &cfg_snk_48_4_2, SCC_SNK_48_4_2);
+ define_test("BAP/UCL/SCC/BV-081-C [UCL SRC Config QoS, LC3 48_5_2]",
+ test_client, &cfg_snk_48_5_2, SCC_SNK_48_5_2);
+ define_test("BAP/UCL/SCC/BV-082-C [UCL SRC Config QoS, LC3 48_6_2]",
+ test_client, &cfg_snk_48_6_2, SCC_SNK_48_6_2);
+ define_test("BAP/UCL/SCC/BV-083-C [UCL SNK Config QoS, LC3 8_1_2]",
+ test_client, &cfg_src_8_1_2, SCC_SRC_8_1_2);
+ define_test("BAP/UCL/SCC/BV-084-C [UCL SNK Config QoS, LC3 8_2_2]",
+ test_client, &cfg_src_8_2_2, SCC_SRC_8_2_2);
+ define_test("BAP/UCL/SCC/BV-085-C [UCL SNK Config QoS, LC3 16_1_2]",
+ test_client, &cfg_src_16_1_2, SCC_SRC_16_1_2);
+ define_test("BAP/UCL/SCC/BV-086-C [UCL SNK Config QoS, LC3 16_2_2]",
+ test_client, &cfg_src_16_2_2, SCC_SRC_16_2_2);
+ define_test("BAP/UCL/SCC/BV-087-C [UCL SNK Config QoS, LC3 24_1_2]",
+ test_client, &cfg_src_24_1_2, SCC_SRC_24_1_2);
+ define_test("BAP/UCL/SCC/BV-088-C [UCL SNK Config QoS, LC3 24_2_2]",
+ test_client, &cfg_src_24_2_2, SCC_SRC_24_2_2);
+ define_test("BAP/UCL/SCC/BV-089-C [UCL SNK Config QoS, LC3 32_1_2]",
+ test_client, &cfg_src_32_1_2, SCC_SRC_32_1_2);
+ define_test("BAP/UCL/SCC/BV-090-C [UCL SNK Config QoS, LC3 32_2_2]",
+ test_client, &cfg_src_32_2_2, SCC_SRC_32_2_2);
+ define_test("BAP/UCL/SCC/BV-091-C [UCL SNK Config QoS, LC3 44.1_1_2]",
+ test_client, &cfg_src_44_1_2, SCC_SRC_44_1_2);
+ define_test("BAP/UCL/SCC/BV-092-C [UCL SNK Config QoS, LC3 44.1_2_2]",
+ test_client, &cfg_src_44_2_2, SCC_SRC_44_2_2);
+ define_test("BAP/UCL/SCC/BV-093-C [UCL SNK Config QoS, LC3 48_1_2]",
+ test_client, &cfg_src_48_1_2, SCC_SRC_48_1_2);
+ define_test("BAP/UCL/SCC/BV-094-C [UCL SNK Config QoS, LC3 48_2_2]",
+ test_client, &cfg_src_48_2_2, SCC_SRC_48_2_2);
+ define_test("BAP/UCL/SCC/BV-095-C [UCL SNK Config QoS, LC3 48_3_2]",
+ test_client, &cfg_src_48_3_2, SCC_SRC_48_3_2);
+ define_test("BAP/UCL/SCC/BV-096-C [UCL SNK Config QoS, LC3 48_4_2]",
+ test_client, &cfg_src_48_4_2, SCC_SRC_48_4_2);
+ define_test("BAP/UCL/SCC/BV-097-C [UCL SNK Config QoS, LC3 48_5_2]",
+ test_client, &cfg_src_48_5_2, SCC_SRC_48_5_2);
+ define_test("BAP/UCL/SCC/BV-098-C [UCL SNK Config QoS, LC3 48_6_2]",
+ test_client, &cfg_src_48_6_2, SCC_SRC_48_6_2);
+}
+
static void test_scc(void)
{
test_scc_cc_lc3();
test_scc_cc_vs();
+ test_scc_qos_lc3();
}
int main(int argc, char *argv[])
--
2.43.0
This is automated email and please do not reply to this email!
Dear submitter,
Thank you for submitting the patches to the linux bluetooth mailing list.
This is a CI test results with your patch series:
PW Link:https://patchwork.kernel.org/project/bluetooth/list/?series=805711
---Test result---
Test Summary:
CheckPatch FAIL 1.51 seconds
GitLint PASS 0.39 seconds
BuildEll PASS 24.94 seconds
BluezMake PASS 664.19 seconds
MakeCheck PASS 11.78 seconds
MakeDistcheck PASS 154.38 seconds
CheckValgrind PASS 216.26 seconds
CheckSmatch PASS 319.98 seconds
bluezmakeextell PASS 100.07 seconds
IncrementalBuild PASS 1131.18 seconds
ScanBuild PASS 907.53 seconds
Details
##############################
Test: CheckPatch - FAIL
Desc: Run checkpatch.pl script
Output:
[BlueZ,v1,2/2] test-bap: Introduce QoS tests for LC3
WARNING:COMMIT_LOG_LONG_LINE: Possible unwrapped commit description (prefer a maximum 75 chars per line)
#78:
Verify that a Unicast Client IUT can initiate a Config QoS operation for the
/github/workspace/src/src/13474875.patch total: 0 errors, 1 warnings, 992 lines checked
NOTE: For some of the reported defects, checkpatch may be able to
mechanically convert to the typical style using --fix or --fix-inplace.
/github/workspace/src/src/13474875.patch has style problems, please review.
NOTE: Ignored message types: COMMIT_MESSAGE COMPLEX_MACRO CONST_STRUCT FILE_PATH_CHANGES MISSING_SIGN_OFF PREFER_PACKED SPDX_LICENSE_TAG SPLIT_STRING SSCANF_TO_KSTRTO
NOTE: If any of the errors are false positives, please report
them to the maintainer, see CHECKPATCH in MAINTAINERS.
---
Regards,
Linux Bluetooth