diff options
author | Seung-Woo Kim <sw0312.kim@samsung.com> | 2013-11-05 03:15:42 -0500 |
---|---|---|
committer | Gustavo Padovan <gustavo.padovan@collabora.co.uk> | 2013-11-13 08:36:53 -0500 |
commit | 8992da099332db896144465a01ad636f58bdebd9 (patch) | |
tree | 0136b0bbd536ab6c21ea9025768b5a912546ce36 /net | |
parent | c507f138fc7c2025d75b65018810dc0561d0bdb9 (diff) |
Bluetooth: Fix to set proper bdaddr_type for RFCOMM connect
L2CAP socket validates proper bdaddr_type for connect, so this
patch fixes to set explictly bdaddr_type for RFCOMM connect.
Signed-off-by: Seung-Woo Kim <sw0312.kim@samsung.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'net')
-rw-r--r-- | net/bluetooth/rfcomm/core.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/bluetooth/rfcomm/core.c b/net/bluetooth/rfcomm/core.c index 292fa64a19dd..ce7521120d69 100644 --- a/net/bluetooth/rfcomm/core.c +++ b/net/bluetooth/rfcomm/core.c | |||
@@ -720,6 +720,7 @@ static struct rfcomm_session *rfcomm_session_create(bdaddr_t *src, | |||
720 | addr.l2_family = AF_BLUETOOTH; | 720 | addr.l2_family = AF_BLUETOOTH; |
721 | addr.l2_psm = __constant_cpu_to_le16(RFCOMM_PSM); | 721 | addr.l2_psm = __constant_cpu_to_le16(RFCOMM_PSM); |
722 | addr.l2_cid = 0; | 722 | addr.l2_cid = 0; |
723 | addr.l2_bdaddr_type = BDADDR_BREDR; | ||
723 | *err = kernel_connect(sock, (struct sockaddr *) &addr, sizeof(addr), O_NONBLOCK); | 724 | *err = kernel_connect(sock, (struct sockaddr *) &addr, sizeof(addr), O_NONBLOCK); |
724 | if (*err == 0 || *err == -EINPROGRESS) | 725 | if (*err == 0 || *err == -EINPROGRESS) |
725 | return s; | 726 | return s; |