* [PATCH BlueZ v1] monitor: Fix printing subpages bits after all subpages
@ 2026-07-10 18:50 Luiz Augusto von Dentz
2026-07-10 20:45 ` [BlueZ,v1] " bluez.test.bot
0 siblings, 1 reply; 2+ messages in thread
From: Luiz Augusto von Dentz @ 2026-07-10 18:50 UTC (permalink / raw)
To: linux-bluetooth
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
This fixes printing the decoded subpage bitfields after all subpages
rather then after the subpage itself:
before:
Features[1/0][8]:
00 03 00 00 00 00 00 00 ........
Features[1/1][8]:
00 00 00 00 00 00 00 00 ........
Features[1/2][8]:
00 00 00 00 00 00 00 00 ........
Shorter Connection Intervals
Shorter Connection Intervals (Host Support)
after:
Features[1/0][8]:
00 03 00 00 00 00 00 00 ........
Shorter Connection Intervals
Shorter Connection Intervals (Host Support)
---
monitor/packet.c | 33 +++++++++++++++++----------------
1 file changed, 17 insertions(+), 16 deletions(-)
diff --git a/monitor/packet.c b/monitor/packet.c
index e62ad4cfb337..ba6ff8e8e551 100644
--- a/monitor/packet.c
+++ b/monitor/packet.c
@@ -2925,17 +2925,29 @@ static const struct bitfield_data features_msft[] = {
static void print_features_subpage(uint8_t page, uint8_t subpages,
const uint8_t *features_array,
- uint64_t *features)
+ uint64_t *features,
+ const struct bitfield_data *table)
{
int i, j;
char str[18];
for (i = 0; i < subpages; i++) {
+ uint64_t mask;
+
for (j = 0; j < 8; j++)
features[i] |= ((uint64_t) features_array[i * 8 + j])
<< (j * 8);
sprintf(str, "Features[%u/%u]", page, i);
print_hex_field(str, &features_array[i * 8], 8);
+
+ if (!table)
+ continue;
+
+ mask = print_bitfield(2, features[i], table);
+ if (mask)
+ print_text(COLOR_UNKNOWN_FEATURE_BIT,
+ " Unknown features (0x%16.16" PRIx64 ")",
+ mask);
}
}
@@ -2943,16 +2955,13 @@ static void print_features(uint8_t page, const uint8_t *features_array,
uint8_t type)
{
const struct bitfield_data *features_table = NULL;
- uint64_t mask, features[3] = {};
+ uint64_t features[3] = {};
uint8_t subpages = 1;
- int i;
/* LE pages 1-10 are 192 bits (24 octets) each */
if (type == 0x01 && page)
subpages = 3;
- print_features_subpage(page, subpages, features_array, features);
-
switch (type) {
case 0x00:
switch (page) {
@@ -2985,16 +2994,8 @@ static void print_features(uint8_t page, const uint8_t *features_array,
break;
}
- if (!features_table)
- return;
-
- for (i = 0; i < subpages; i++) {
- mask = print_bitfield(2, features[i], features_table);
- if (mask)
- print_text(COLOR_UNKNOWN_FEATURE_BIT,
- " Unknown features (0x%16.16" PRIx64 ")",
- mask);
- }
+ print_features_subpage(page, subpages, features_array, features,
+ features_table);
}
void packet_print_features_lmp(const uint8_t *features, uint8_t page)
@@ -11065,7 +11066,7 @@ static const struct opcode_data opcode_table[] = {
"LE Read Minimum Supported Connection Interval",
null_cmd, 0, true, le_read_conn_interval_rsp,
sizeof(struct bt_hci_rsp_le_read_conn_interval),
- true },
+ false },
{ }
};
--
2.54.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* RE: [BlueZ,v1] monitor: Fix printing subpages bits after all subpages
2026-07-10 18:50 [PATCH BlueZ v1] monitor: Fix printing subpages bits after all subpages Luiz Augusto von Dentz
@ 2026-07-10 20:45 ` bluez.test.bot
0 siblings, 0 replies; 2+ messages in thread
From: bluez.test.bot @ 2026-07-10 20:45 UTC (permalink / raw)
To: linux-bluetooth, luiz.dentz
[-- Attachment #1: Type: text/plain, Size: 9742 bytes --]
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=1125561
---Test result---
Test Summary:
CheckPatch PASS 0.30 seconds
GitLint PASS 0.20 seconds
BuildEll PASS 16.46 seconds
BluezMake FAIL 424.88 seconds
MakeCheck FAIL 14.35 seconds
MakeDistcheck PASS 124.15 seconds
CheckValgrind FAIL 99.26 seconds
CheckSmatch WARNING 228.48 seconds
bluezmakeextell PASS 76.29 seconds
IncrementalBuild FAIL 431.35 seconds
ScanBuild PASS 708.33 seconds
Details
##############################
Test: BluezMake - FAIL
Desc: Build BlueZ
Output:
tools/mgmt-tester.c: In function ‘main’:
tools/mgmt-tester.c:12990:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
12990 | int main(int argc, char *argv[])
| ^~~~
unit/test-avdtp.c: In function ‘main’:
unit/test-avdtp.c:766:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
766 | int main(int argc, char *argv[])
| ^~~~
unit/test-avrcp.c: In function ‘main’:
unit/test-avrcp.c:989:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
989 | int main(int argc, char *argv[])
| ^~~~
monitor/packet.c: In function ‘print_features_subpage’:
monitor/packet.c:2940:29: error: ‘%u’ directive writing between 1 and 10 bytes into a region of size between 5 and 7 [-Werror=format-overflow=]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~
monitor/packet.c:2940:16: note: directive argument in the range [0, 2147483646]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/stdio.h:867,
from monitor/packet.c:18:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output between 14 and 25 bytes into a destination of size 18
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:7058: monitor/packet.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:4172: all] Error 2
##############################
Test: MakeCheck - FAIL
Desc: Run Bluez Make Check
Output:
monitor/packet.c: In function ‘print_features_subpage’:
monitor/packet.c:2940:29: error: ‘%u’ directive writing between 1 and 10 bytes into a region of size between 5 and 7 [-Werror=format-overflow=]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~
monitor/packet.c:2940:16: note: directive argument in the range [0, 2147483646]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/stdio.h:867,
from monitor/packet.c:18:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output between 14 and 25 bytes into a destination of size 18
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:7058: monitor/packet.o] Error 1
make: *** [Makefile:10820: check] Error 2
##############################
Test: CheckValgrind - FAIL
Desc: Run Bluez Make Check with Valgrind
Output:
tools/mgmt-tester.c: In function ‘main’:
tools/mgmt-tester.c:12990:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
12990 | int main(int argc, char *argv[])
| ^~~~
monitor/packet.c: In function ‘print_features_subpage’:
monitor/packet.c:2940:29: error: ‘%u’ directive writing between 1 and 10 bytes into a region of size between 5 and 7 [-Werror=format-overflow=]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~
monitor/packet.c:2940:16: note: directive argument in the range [0, 2147483646]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/stdio.h:867,
from monitor/packet.c:18:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output between 14 and 25 bytes into a destination of size 18
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:7058: monitor/packet.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:10820: check] Error 2
##############################
Test: CheckSmatch - WARNING
Desc: Run smatch tool with source
Output:
monitor/packet.c:2002:26: warning: Variable length array is used.monitor/packet.c: note: in included file:monitor/bt.h:3924:52: warning: array of flexible structuresmonitor/bt.h:3912:40: warning: array of flexible structures
##############################
Test: IncrementalBuild - FAIL
Desc: Incremental build with the patches in the series
Output:
tools/mgmt-tester.c: In function ‘main’:
tools/mgmt-tester.c:12990:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
12990 | int main(int argc, char *argv[])
| ^~~~
unit/test-avdtp.c: In function ‘main’:
unit/test-avdtp.c:766:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
766 | int main(int argc, char *argv[])
| ^~~~
unit/test-avrcp.c: In function ‘main’:
unit/test-avrcp.c:989:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
989 | int main(int argc, char *argv[])
| ^~~~
monitor/packet.c: In function ‘print_features_subpage’:
monitor/packet.c:2940:29: error: ‘%u’ directive writing between 1 and 10 bytes into a region of size between 5 and 7 [-Werror=format-overflow=]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~
monitor/packet.c:2940:16: note: directive argument in the range [0, 2147483646]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/stdio.h:867,
from monitor/packet.c:18:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output between 14 and 25 bytes into a destination of size 18
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:7058: monitor/packet.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:4172: all] Error 2
[BlueZ,v1] monitor: Fix printing subpages bits after all subpages
tools/mgmt-tester.c: In function ‘main’:
tools/mgmt-tester.c:12990:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
12990 | int main(int argc, char *argv[])
| ^~~~
unit/test-avdtp.c: In function ‘main’:
unit/test-avdtp.c:766:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
766 | int main(int argc, char *argv[])
| ^~~~
unit/test-avrcp.c: In function ‘main’:
unit/test-avrcp.c:989:5: note: variable tracking size limit exceeded with ‘-fvar-tracking-assignments’, retrying without
989 | int main(int argc, char *argv[])
| ^~~~
monitor/packet.c: In function ‘print_features_subpage’:
monitor/packet.c:2940:29: error: ‘%u’ directive writing between 1 and 10 bytes into a region of size between 5 and 7 [-Werror=format-overflow=]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~
monitor/packet.c:2940:16: note: directive argument in the range [0, 2147483646]
2940 | sprintf(str, "Features[%u/%u]", page, i);
| ^~~~~~~~~~~~~~~~~
In file included from /usr/include/stdio.h:867,
from monitor/packet.c:18:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:36:10: note: ‘__builtin___sprintf_chk’ output between 14 and 25 bytes into a destination of size 18
36 | return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
37 | __bos (__s), __fmt, __va_arg_pack ());
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
cc1: all warnings being treated as errors
make[1]: *** [Makefile:7058: monitor/packet.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [Makefile:4172: all] Error 2
https://github.com/bluez/bluez/pull/2296
---
Regards,
Linux Bluetooth
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2026-07-10 20:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-10 18:50 [PATCH BlueZ v1] monitor: Fix printing subpages bits after all subpages Luiz Augusto von Dentz
2026-07-10 20:45 ` [BlueZ,v1] " bluez.test.bot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox