aboutsummaryrefslogtreecommitdiffstats
path: root/net/bluetooth/l2cap_core.c (follow)
AgeCommit message (Collapse)AuthorFilesLines
2011-02-27Bluetooth: Use ERR_PTR as return error from hci_connectVille Tervo1-5/+6
Use ERR_PTR mechanism to return error from hci_connect. Signed-off-by: Ville Tervo <ville.tervo@nokia.com> Signed-off-by: Anderson Briglia <anderson.briglia@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-25Bluetooth: Remove duplicated BT_INFO() from L2CAPGustavo F. Padovan1-2/+0
The message for the initialization of the L2CAP layer was being printed twice. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-17Bluetooth: fix errors reported by checkpatch.plGustavo F. Padovan1-7/+3
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-16Bluetooth: Send LE Connection Update CommandClaudio Takahasi1-1/+7
If the new connection update parameter are accepted, the LE master host sends the LE Connection Update Command to its controller informing the new requested parameters. Signed-off-by: Claudio Takahasi <claudio.takahasi@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-16Bluetooth: Add connection parameter update responseClaudio Takahasi1-1/+58
Implements L2CAP Connection Parameter Update Response defined in the Bluetooth Core Specification, Volume 3, Part A, section 4.21. Address the LE Connection Parameter Procedure initiated by the slave. Connection Interval Minimum and Maximum have the same range: 6 to 3200. Time = N * 1.25ms. Minimum shall be less or equal to Maximum. The Slave Latency field shall have a value in the range of 0 to ((connSupervisionTimeout / connIntervalMax) - 1). Latency field shall be less than 500. connSupervisionTimeout = Timeout Multiplier * 10 ms. Multiplier field shall have a value in the range of 10 to 3200. Signed-off-by: Claudio Takahasi <claudio.takahasi@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-16Bluetooth: Add LE signaling commands handlingClaudio Takahasi1-52/+90
This patch splits the L2CAP command handling function in order to have a clear separation between the commands related to BR/EDR and LE. Commands and responses in the LE signaling channel are not being handled yet, command reject is sent to all received requests. Bluetooth Core Specification, Volume 3, Part A, section 4 defines the signaling packets formats and allowed commands/responses over the LE signaling channel. Signed-off-by: Claudio Takahasi <claudio.takahasi@openbossa.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-16Bluetooth: Add server socket support for LE connectionVille Tervo1-3/+91
Add support for LE server sockets. Signed-off-by: Ville Tervo <ville.tervo@nokia.com> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-16Bluetooth: Add LE connection support to L2CAPVille Tervo1-4/+19
Add basic LE connection support to L2CAP. LE connection can be created by specifying cid in struct sockaddr_l2 Signed-off-by: Ville Tervo <ville.tervo@nokia.com> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-15Bluetooth: Add L2CAP mode to debugfs outputGustavo F. Padovan1-2/+3
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-15Bluetooth: remove l2cap_load() hackGustavo F. Padovan1-8/+0
l2cap_load() was added to trigger l2cap.ko module loading from the RFCOMM and BNEP modules. Now that L2CAP module is gone, we don't need it anymore. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-14Bluetooth: Merge L2CAP and SCO modules into bluetooth.koGustavo F. Padovan1-14/+2
Actually doesn't make sense have these modules built separately. The L2CAP layer is needed by almost all Bluetooth protocols and profiles. There isn't any real use case without having L2CAP loaded. SCO is only essential for Audio transfers, but it is so small that we can have it loaded always in bluetooth.ko without problems. If you really doesn't want it you can disable SCO in the kernel config. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move __l2cap_sock_close() to l2cap_sock.cGustavo F. Padovan1-83/+2
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_kill() to l2cap_sock.cGustavo F. Padovan1-16/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move L2CAP sock timers function to l2cap_sock.cGustavo F. Padovan1-13/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_sendmsg() to l2cap_sock.cGustavo F. Padovan1-109/+7
Also moves some L2CAP sending functions declaration to l2cap.h Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_shutdown() to l2cap_sock.cGustavo F. Padovan1-33/+2
Declare __l2cap_wait_ack() and l2cap_sock_clear_timer() in l2cap.h Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_recvmsg() to l2cap_sock.cGustavo F. Padovan1-46/+3
It causes the move of the declaration of 3 functions to l2cap.h: l2cap_get_ident(), l2cap_send_cmd(), l2cap_build_conf_req() Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_connect() to l2cap_sock.cGustavo F. Padovan1-86/+1
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_getsockopt() to l2cap_sock.cGustavo F. Padovan1-145/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_setsockopt() to l2cap_sock.cGustavo F. Padovan1-174/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_getname() to l2cap_sock.cGustavo F. Padovan1-23/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_accept() to l2cap_sock.cGustavo F. Padovan1-56/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_bind()/listen() to l2cap_sock.cGustavo F. Padovan1-134/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_release() to l2cap_sock.cGustavo F. Padovan1-17/+0
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: move l2cap_sock_ops to l2cap_sock.cGustavo F. Padovan1-31/+11
First step to move all l2cap_sock_ops function to l2cap_sock.c Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: Initial work for L2CAP split.Gustavo F. Padovan1-176/+11
This patch tries to do the minimal to move l2cap_sock_create() and its dependencies to l2cap_sock.c. It create a API to initialize and cleanup the L2CAP sockets from l2cap_core.c through l2cap_init_sockets() and l2cap_cleanup_sockets(). Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
2011-02-08Bluetooth: Rename l2cap.c to l2cap_core.cGustavo F. Padovan1-0/+4984
In a preparation to the the L2CAP code split in many files. Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>