Skip to contentSkip to conversation

l2test: Send failed. Invalid argument(22)

Bluez-users Przemek 2 participants 3 messages May 6, 2004 Bluetooth drivers

lore
Share & tools
lore

Przemek

author
#0 lore raw

Hi!

I'm trying to test (almost) my implementation of L2CAP. This is what i do:

$ ./l2test -s -N 20 -S 00:0A:3A:53:12:4A 00:80:37:16:30:8B

Unfortunetly, I get:

l2test[2445]: Connected [imtu 672, omtu 512, flush_to 65535] l2test[2445]: Sending ...
l2test[2445]: Send failed. Invalid argument(22)

No data is send. Just after L2CAP connection is established my module is receiving Disconnection Request packet.

Please, tell me, what does that "Invalid argument(22)" mean.

Best regards,
Przemek

-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

maintainer
#1 lore raw

Hi Przemek,

Quoted 7 lines

I'm trying to test (almost) my implementation of L2CAP. This is what i do:

$ ./l2test -s -N 20 -S 00:0A:3A:53:12:4A 00:80:37:16:30:8B

Unfortunetly, I get:

Quoted 8 lines

l2test[2445]: Connected [imtu 672, omtu 512, flush_to 65535] l2test[2445]: Sending ...
l2test[2445]: Send failed. Invalid argument(22)

No data is send. Just after L2CAP connection is established my module is receiving Disconnection Request packet.

Please, tell me, what does that "Invalid argument(22)" mean.

you are using BlueZ to test your own implementation of L2CAP. Sounds nice, but you already got all you need. Run hcidump and see what is going on the HCI level. If you are looking for the error code than check errno and the L2CAP source code. From a quick view it looks like your data is bigger than your MTU. L2CAP is sequential packet and not a stream.

Regards

Marcel

-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users

author
#2 lore raw
Quoted 3 lines · Marcel Holtmann

From a quick view it looks like your
data is bigger than your MTU. L2CAP is sequential packet and not a stream.

That's right! I should have used -b option with l2test. Thank you vary much!

Best regards,
Przemek

-------------------------------------------------------
This SF.Net email is sponsored by Sleepycat Software
Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO.
http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3
_______________________________________________
Bluez-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/bluez-users