Szymon Janc
d4199a012d
android: Add ipc_send_rsp_full IPC helper
...
This will be used to send non-empty reply using command socket.
2013-11-28 18:02:27 +02:00
Szymon Janc
daf1186c38
android: Use ipc_send_notif for sending notifications
2013-11-28 18:02:26 +02:00
Szymon Janc
066eac37ad
android: Add IPC helper for sending notifications
...
This will use notification socket passed on IPC init.
2013-11-28 18:02:26 +02:00
Szymon Janc
a50edbf560
android: Use ipc_send_rsp helper for replying success
...
Where applicable use helper as this make code easier to understand.
2013-11-28 18:02:26 +02:00
Szymon Janc
6456e15664
android: Remove socket parameter from ipc_send_rsp
...
Use command socket provided to IPC on init.
2013-11-28 18:02:26 +02:00
Szymon Janc
4f1d080aa7
android: Initialize IPC with command and notification sockets
...
Pass sockets after succesfully connected to HAL. This will allow
to improve IPC helpers API.
2013-11-28 18:02:26 +02:00
Jakub Tyszkowski
f5899e36a4
android/pics: Add PIXIT setup info to PICS files
...
Some profiles like DID, requires specific PIXIT setup to pass some tests
cases. Other profiles works well with defaults. Thus appropriate
information at the end of PICS file should be provided.
2013-11-28 16:47:05 +02:00
Jakub Tyszkowski
d6cd131128
android/pics: Add PTS PICS for PBAP
...
PTS PICS for PBAP, targeting Android 4.4.
2013-11-28 16:47:03 +02:00
Jakub Tyszkowski
3244fc249d
android/pics: Add PTS PICS for OPP
...
PTS PICS for OPP, targeting Android 4.4.
2013-11-28 11:44:08 +02:00
Ravi kumar Veeramally
99fcb3fc01
android: Add CAP_NET_RAW capability
...
CAP_NET_RAW capability is required to up the bnep interfaces
in android environment.
2013-11-27 13:06:44 +02:00
Szymon Janc
63681815bd
android/bluetooth: Change discoverable mode only if connectable
...
There is no need to sending set_discoverable command if new settings
are not connectable as clearing connectable also clear discoverable.
Sending set_discoverable when not connectable result in 'rejected'
mgmt response.
2013-11-27 12:57:04 +02:00
Johan Hedberg
c95d6263f5
android/socket: Remove useless dst variable
2013-11-27 12:56:41 +02:00
Andrei Emeltchenko
41631e8b46
android/socket: Check create_rfsock returns valid structure
2013-11-27 12:54:37 +02:00
Andrei Emeltchenko
7c48f46ed1
android/hal-sock: Check uuid before dereference
...
uuid might be NULL and channel might be specified which makes it
valid case for Android. This adds check for uuid and service name.
2013-11-27 12:53:41 +02:00
Johan Hedberg
cc38f090de
android: Fix pointless eir debug log
2013-11-27 12:52:29 +02:00
Andrei Emeltchenko
bb712ac791
android/socket: Use security level for connect / listen
...
Use MEDIUM security level for connections without profile and default
sec_level for others. rfsock now has pointer to profile info.
2013-11-26 17:44:05 +02:00
Andrei Emeltchenko
b3c8fbbb66
android/socket: Make profile struct const
...
We are not supposed to change profile structure, make it const.
2013-11-26 17:43:27 +02:00
Andrei Emeltchenko
3cc6ed2d30
android/haltest: Add uuid autocompletions
2013-11-26 17:42:36 +02:00
Andrei Emeltchenko
7eac27334f
android/haltest: trivial: Fix typo channle -> channel
2013-11-26 17:42:25 +02:00
Luiz Augusto von Dentz
21b1bd698b
android/AVDTP: Strip dependencies
...
This strips AVDTP code of any dependency of core and btio to make it
transport agnostic.
2013-11-25 16:50:31 +02:00
Luiz Augusto von Dentz
e40bfde22e
android: Add copy of current AVDTP implemention
...
These files are not added to any makefile on purpose because they still
have external dependencies.
2013-11-25 15:59:28 +02:00
Andrei Emeltchenko
a7f01b2e1b
android/socket: Add error printing possible close() failure
2013-11-25 15:37:17 +02:00
Andrei Emeltchenko
407789abea
android/socket: Use default sec_level for listen
...
Set default security level low for OPP and SPP and medium for PBAP and MAS.
Default security level would be low for listening without profile.
2013-11-25 15:36:25 +02:00
Andrei Emeltchenko
1c2efb5093
android/hal-utils: Fix possible NULL pointer dereference
2013-11-25 15:34:15 +02:00
Andrei Emeltchenko
ed7452fbbf
android/socket: Refactor socket send_fd function
...
Make code cleaner and initialize local cmsg buffer to zeroes.
2013-11-25 15:32:31 +02:00
Andrei Emeltchenko
b975a903fb
android/hal-sock: Print bdaddr on connect
2013-11-25 15:32:14 +02:00
Andrei Emeltchenko
d84ffb05e3
android/socket: Support listen() with supplied chan number
...
No profile is assigned in this case. There is a possibility to use
Serial Port Profile.
2013-11-25 15:32:07 +02:00
Andrei Emeltchenko
27d036281a
android/socket: Add SPP SDP record
2013-11-25 15:30:42 +02:00
Andrei Emeltchenko
980ffed8d7
android/socket: Add PBAP SDP record
...
This adds SDP service record like shown below:
Service Name: OBEX Phonebook Access Server
Service RecHandle: 0x10002
Service Class ID List:
"Phonebook Access - PSE" (0x112f)
Protocol Descriptor List:
"RFCOMM" (0x0003)
Channel: 15
"OBEX" (0x0008)
Profile Descriptor List:
"Phonebook Access" (0x1130)
Version: 0x0100
2013-11-25 15:30:33 +02:00
Andrei Emeltchenko
58ab9edb8a
android/socket: Add SPP uuid to profile table
2013-11-25 15:30:24 +02:00
Andrei Emeltchenko
b1e23ebd37
android/socket: Add MAS uuid to profile table
2013-11-25 15:30:13 +02:00
Andrei Emeltchenko
30d49b2b3a
android/socket: Add OPP SDP record
...
This adds SDP record for OPP shown below:
Service Name: OBEX Object Push
Service RecHandle: 0x10002
Service Class ID List:
"OBEX Object Push" (0x1105)
Protocol Descriptor List:
"RFCOMM" (0x0003)
Channel: 9
"OBEX" (0x0008)
Profile Descriptor List:
"OBEX Object Push" (0x1105)
Version: 0x0100
2013-11-25 15:29:58 +02:00
Andrei Emeltchenko
181158d8e6
android/socket: Add general service create/remove function
...
create_record function from profile is used to create SDP service record.
The record is removed from rfsock cleanup function.
2013-11-25 15:29:15 +02:00
Andrei Emeltchenko
cb2fdb2f53
android/socket: Close file descriptor after sending
2013-11-25 15:28:29 +02:00
Andrei Emeltchenko
7a9c4622e4
android/socket: Send connect signal to Android framework
...
Android framework expects connect signal to be sent when
remote device is connected.
2013-11-25 15:28:01 +02:00
Andrei Emeltchenko
c8226366a8
android/socket: Send RFCOMM channel to framework
...
Framework expects channel to be send.
2013-11-25 15:27:00 +02:00
Andrei Emeltchenko
a1deeaf589
android/socket: Implement HAL connect call
...
HAL connect uses similar event handlers like listen call.
2013-11-25 15:26:03 +02:00
Andrei Emeltchenko
9b33ebad23
android/socket: Parse SDP response and connect
...
Parse SDP response, find RFCOMM channel and connect.
2013-11-25 15:25:52 +02:00
Andrei Emeltchenko
044baf78ef
android/bluetooth: Fix memory leak
2013-11-25 14:51:08 +02:00
Jakub Tyszkowski
47536a57a9
android/pics: Add PTS PICS for DID
...
PTS PICS for DID, targeting Android 4.4.
2013-11-25 14:47:40 +02:00
Jakub Tyszkowski
9942252e00
android/pics: Add PTS PICS for PAN
...
PTS PICS for PAN, targeting Android 4.4.
2013-11-25 14:47:40 +02:00
Szymon Janc
034e30e642
android/hal-bluetooth: Use static memory for enum convertion
...
There is no need to use dynamic allocation for enum properties
convertion. Each property type can be present only once in properties
callback so using static allocation is safe. This also remove need
for cleanup properties after HAL callback is called making code
simpler.
2013-11-25 14:45:59 +02:00
Andrei Emeltchenko
71e455c8b9
android/haltest: Zero initialize cmsg buffer
2013-11-21 16:43:40 +02:00
Andrei Emeltchenko
e73bd888be
android/ipc: Zero initialize cmsg buffer
...
This fixes valgrind warnings:
...
Syscall param sendmsg(msg.msg_control) points to uninitialised byte(s)
...
2013-11-21 16:43:38 +02:00
Luiz Augusto von Dentz
ee750796da
android/a2dp: Cleanup devices on unregister
...
This cleanup any existing devices in bt_a2dp_unregister
2013-11-21 10:15:51 +02:00
Andrei Emeltchenko
7ee3686348
android/socket: Implement socket connect HAL method
...
First step is to query remote device for RFCOMM channel.
2013-11-20 15:10:53 +02:00
Andrei Emeltchenko
002a64f595
android/socket: Notify channel to Android framework
...
Android framework expects to receive channel number as int.
2013-11-20 15:10:45 +02:00
Andrei Emeltchenko
34c4ae9ad8
android/socket: Send accept signal to Android framework
...
Android expects to get accept signal over file descriptor which was
set during listen HAL call.
2013-11-20 15:10:17 +02:00
Andrei Emeltchenko
cfc5e2ae33
android/socket: Implement RFCOMM events
...
Copy data from RFCOMM socket to Android framework. Consider splice
in the future.
2013-11-20 15:10:03 +02:00
Andrei Emeltchenko
601cfc775e
android/socket: Implement Android RFCOMM stack events
...
Handle events from Android framework. Write everything to real RFCOMM
socket. Consider splice() in the future.
2013-11-20 15:09:02 +02:00