Linux bluetooth development
 help / color / mirror / Atom feed
* [PATCH BlueZ v2] l2test: Fix calling getsockopt(BT_PHY)
@ 2026-07-07 14:55 Luiz Augusto von Dentz
  2026-07-07 16:45 ` [BlueZ,v2] " bluez.test.bot
  2026-07-07 18:40 ` [PATCH BlueZ v2] " patchwork-bot+bluetooth
  0 siblings, 2 replies; 3+ messages in thread
From: Luiz Augusto von Dentz @ 2026-07-07 14:55 UTC (permalink / raw)
  To: linux-bluetooth

From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>

getsockopt(BT_PHY) expectes a 32 bits argument not a
sizeof(struct sockaddr_l2).
---
 tools/l2test.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/tools/l2test.c b/tools/l2test.c
index aa05f5247c5e..08d2269936b9 100644
--- a/tools/l2test.c
+++ b/tools/l2test.c
@@ -358,7 +358,8 @@ static int print_info(int sk, struct l2cap_options *opts)
 	struct sockaddr_l2 addr;
 	socklen_t optlen;
 	struct l2cap_conninfo conn;
-	int prio, phy;
+	int prio;
+	uint32_t phy;
 	char ba[18];
 
 	/* Get connection information */
@@ -414,6 +415,8 @@ static int print_info(int sk, struct l2cap_options *opts)
 		conn.dev_class[0], prio, rcvbuf);
 
 
+	optlen = sizeof(phy);
+
 	if (!getsockopt(sk, SOL_BLUETOOTH, BT_PHY, &phy, &optlen)) {
 		syslog(LOG_INFO, "Supported PHY: 0x%08x", phy);
 		print_bitfield(2, phy, phy_table);
-- 
2.54.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* RE: [BlueZ,v2] l2test: Fix calling getsockopt(BT_PHY)
  2026-07-07 14:55 [PATCH BlueZ v2] l2test: Fix calling getsockopt(BT_PHY) Luiz Augusto von Dentz
@ 2026-07-07 16:45 ` bluez.test.bot
  2026-07-07 18:40 ` [PATCH BlueZ v2] " patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: bluez.test.bot @ 2026-07-07 16:45 UTC (permalink / raw)
  To: linux-bluetooth, luiz.dentz

[-- Attachment #1: Type: text/plain, Size: 825 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=1123158

---Test result---

Test Summary:
CheckPatch                    PASS      0.28 seconds
GitLint                       PASS      0.31 seconds
BuildEll                      PASS      20.94 seconds
BluezMake                     PASS      569.33 seconds
CheckSmatch                   PASS      315.20 seconds
bluezmakeextell               PASS      102.60 seconds
IncrementalBuild              PASS      557.19 seconds
ScanBuild                     PASS      988.52 seconds



https://github.com/bluez/bluez/pull/2276

---
Regards,
Linux Bluetooth


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH BlueZ v2] l2test: Fix calling getsockopt(BT_PHY)
  2026-07-07 14:55 [PATCH BlueZ v2] l2test: Fix calling getsockopt(BT_PHY) Luiz Augusto von Dentz
  2026-07-07 16:45 ` [BlueZ,v2] " bluez.test.bot
@ 2026-07-07 18:40 ` patchwork-bot+bluetooth
  1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+bluetooth @ 2026-07-07 18:40 UTC (permalink / raw)
  To: Luiz Augusto von Dentz; +Cc: linux-bluetooth

Hello:

This patch was applied to bluetooth/bluez.git (master)
by Luiz Augusto von Dentz <luiz.von.dentz@intel.com>:

On Tue,  7 Jul 2026 10:55:36 -0400 you wrote:
> From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
> 
> getsockopt(BT_PHY) expectes a 32 bits argument not a
> sizeof(struct sockaddr_l2).
> ---
>  tools/l2test.c | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)

Here is the summary with links:
  - [BlueZ,v2] l2test: Fix calling getsockopt(BT_PHY)
    https://git.kernel.org/pub/scm/bluetooth/bluez.git/?id=b84aa8949210

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2026-07-07 18:40 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-07 14:55 [PATCH BlueZ v2] l2test: Fix calling getsockopt(BT_PHY) Luiz Augusto von Dentz
2026-07-07 16:45 ` [BlueZ,v2] " bluez.test.bot
2026-07-07 18:40 ` [PATCH BlueZ v2] " patchwork-bot+bluetooth

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox