Message ID | 20230816150917.7896-2-iulia.tanasescu@nxp.com (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | iso-tester: Add test for bcast receiver defer setup | expand |
Context | Check | Description |
---|---|---|
tedd_an/pre-ci_am | success | Success |
tedd_an/CheckPatch | fail | ERROR:SPACING: need consistent spacing around '*' (ctx:WxV) #131: FILE: tools/iso-tester.c:2353: +static gboolean iso_accept_cb(GIOChannel *io, GIOCondition cond, ^ WARNING:LONG_LINE: line length of 82 exceeds 80 columns #150: FILE: tools/iso-tester.c:2386: + data->io_id[0] = g_io_add_watch(io, G_IO_IN, iso_accept_cb, NULL); WARNING:LONG_LINE: line length of 84 exceeds 80 columns #153: FILE: tools/iso-tester.c:2389: + data->io_id[0] = g_io_add_watch(io, G_IO_OUT, iso_connect_cb, NULL); WARNING:LONG_LINE: line length of 86 exceeds 80 columns #182: FILE: tools/iso-tester.c:2991: + test_iso("ISO Broadcaster Receiver Defer - Success", &bcast_16_2_1_recv_defer, /github/workspace/src/src/13355383.patch total: 1 errors, 3 warnings, 71 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/13355383.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. |
tedd_an/GitLint | success | Gitlint PASS |
tedd_an/BuildEll | success | Build ELL PASS |
tedd_an/BluezMake | success | Bluez Make PASS |
tedd_an/MakeCheck | success | Bluez Make Check PASS |
tedd_an/MakeDistcheck | success | Make Distcheck PASS |
tedd_an/CheckValgrind | success | Check Valgrind PASS |
tedd_an/CheckSmatch | success | CheckSparse PASS |
tedd_an/bluezmakeextell | success | Make External ELL PASS |
tedd_an/IncrementalBuild | success | Incremental Build PASS |
tedd_an/ScanBuild | success | Scan Build PASS |
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=776679 ---Test result--- Test Summary: CheckPatch FAIL 0.76 seconds GitLint PASS 0.27 seconds BuildEll PASS 35.28 seconds BluezMake PASS 1255.12 seconds MakeCheck PASS 13.33 seconds MakeDistcheck PASS 201.74 seconds CheckValgrind PASS 326.91 seconds CheckSmatch PASS 458.96 seconds bluezmakeextell PASS 136.65 seconds IncrementalBuild PASS 1078.93 seconds ScanBuild PASS 1460.57 seconds Details ############################## Test: CheckPatch - FAIL Desc: Run checkpatch.pl script Output: [BlueZ,1/1] iso-tester: Add test for bcast receiver defer setup ERROR:SPACING: need consistent spacing around '*' (ctx:WxV) #131: FILE: tools/iso-tester.c:2353: +static gboolean iso_accept_cb(GIOChannel *io, GIOCondition cond, ^ WARNING:LONG_LINE: line length of 82 exceeds 80 columns #150: FILE: tools/iso-tester.c:2386: + data->io_id[0] = g_io_add_watch(io, G_IO_IN, iso_accept_cb, NULL); WARNING:LONG_LINE: line length of 84 exceeds 80 columns #153: FILE: tools/iso-tester.c:2389: + data->io_id[0] = g_io_add_watch(io, G_IO_OUT, iso_connect_cb, NULL); WARNING:LONG_LINE: line length of 86 exceeds 80 columns #182: FILE: tools/iso-tester.c:2991: + test_iso("ISO Broadcaster Receiver Defer - Success", &bcast_16_2_1_recv_defer, /github/workspace/src/src/13355383.patch total: 1 errors, 3 warnings, 71 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/13355383.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
diff --git a/tools/iso-tester.c b/tools/iso-tester.c index b1a2afba0..d5d2284ab 100644 --- a/tools/iso-tester.c +++ b/tools/iso-tester.c @@ -1134,6 +1134,15 @@ static const struct iso_client_data bcast_enc_16_2_1_recv = { .server = true, }; +static const struct iso_client_data bcast_16_2_1_recv_defer = { + .qos = QOS_IN_16_2_1, + .expect_err = 0, + .defer = true, + .recv = &send_16_2_1, + .bcast = true, + .server = true, +}; + static const struct iso_client_data bcast_ac_12 = { .qos = BCAST_AC_12, .expect_err = 0, @@ -2341,11 +2350,15 @@ static void setup_listen(struct test_data *data, uint8_t num, GIOFunc func) } } +static gboolean iso_accept_cb(GIOChannel *io, GIOCondition cond, + gpointer user_data); + static bool iso_defer_accept(struct test_data *data, GIOChannel *io) { int sk; char c; struct pollfd pfd; + const struct iso_client_data *isodata = data->test_data; sk = g_io_channel_unix_get_fd(io); @@ -2368,7 +2381,13 @@ static bool iso_defer_accept(struct test_data *data, GIOChannel *io) tester_print("Accept deferred setup"); data->io = io; - data->io_id[0] = g_io_add_watch(io, G_IO_OUT, iso_connect_cb, NULL); + + if (isodata->bcast) { + data->io_id[0] = g_io_add_watch(io, G_IO_IN, iso_accept_cb, NULL); + data->step++; + } else { + data->io_id[0] = g_io_add_watch(io, G_IO_OUT, iso_connect_cb, NULL); + } return true; } @@ -2400,6 +2419,11 @@ static gboolean iso_accept_cb(GIOChannel *io, GIOCondition cond, return false; } + if (isodata->bcast && data->step > 1) { + data->step--; + goto connect; + } + if (!iso_defer_accept(data, io)) { tester_warn("Unable to accept deferred setup"); tester_test_failed(); @@ -2419,6 +2443,7 @@ static gboolean iso_accept_cb(GIOChannel *io, GIOCondition cond, } } +connect: return iso_connect(io, cond, user_data); } @@ -2963,6 +2988,9 @@ int main(int argc, char *argv[]) &bcast_enc_16_2_1_recv, setup_powered, test_bcast_recv); + test_iso("ISO Broadcaster Receiver Defer - Success", &bcast_16_2_1_recv_defer, + setup_powered, + test_bcast_recv); test_iso("ISO Broadcaster AC 12 - Success", &bcast_ac_12, setup_powered, test_bcast);