OSDN Git Service

android-x86/external-bluetooth-bluez.git
10 years agobuild: Fix build error if path contains spaces
Szymon Janc [Thu, 28 Nov 2013 11:10:55 +0000 (12:10 +0100)]
build: Fix build error if path contains spaces

janccszy@box:~/bluez test$ make
  GEN      lib/bluetooth/bluetooth.h
ln: target ‘lib/bluetooth/bluetooth.h’ is not a directory
make: *** [lib/bluetooth/bluetooth.h] Error 1

10 years agoandroid/pics: Add PTS PICS for OPP
Jakub Tyszkowski [Thu, 28 Nov 2013 08:04:33 +0000 (09:04 +0100)]
android/pics: Add PTS PICS for OPP

PTS PICS for OPP, targeting Android 4.4.

10 years agobuild: Force GLib version check while building in maintainer mode
Szymon Janc [Wed, 27 Nov 2013 15:44:56 +0000 (16:44 +0100)]
build: Force GLib version check while building in maintainer mode

This will allow to catch up build errors introduced by using GLib API
introduced in newer GLib than minimal required even if building with
newer version.

10 years agoandroid: Add CAP_NET_RAW capability
Ravi kumar Veeramally [Mon, 25 Nov 2013 13:49:26 +0000 (15:49 +0200)]
android: Add CAP_NET_RAW capability

CAP_NET_RAW capability is required to up the bnep interfaces
in android environment.

10 years agounit/AVDTP: Fix using g_test_add_data_func_full
Luiz Augusto von Dentz [Wed, 27 Nov 2013 10:43:01 +0000 (12:43 +0200)]
unit/AVDTP: Fix using g_test_add_data_func_full

g_test_add_data_func_full requires glib 2.34 while the current dependency
is just 2.32.

10 years agoandroid/bluetooth: Change discoverable mode only if connectable
Szymon Janc [Tue, 26 Nov 2013 12:00:26 +0000 (13:00 +0100)]
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.

10 years agoandroid/socket: Remove useless dst variable
Johan Hedberg [Wed, 27 Nov 2013 10:56:41 +0000 (12:56 +0200)]
android/socket: Remove useless dst variable

10 years agoandroid/socket: Check create_rfsock returns valid structure
Andrei Emeltchenko [Tue, 26 Nov 2013 14:05:48 +0000 (16:05 +0200)]
android/socket: Check create_rfsock returns valid structure

10 years agoandroid/hal-sock: Check uuid before dereference
Andrei Emeltchenko [Tue, 26 Nov 2013 14:05:49 +0000 (16:05 +0200)]
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.

10 years agoandroid: Fix pointless eir debug log
Johan Hedberg [Wed, 27 Nov 2013 10:52:29 +0000 (12:52 +0200)]
android: Fix pointless eir debug log

10 years agoinput: Rename check_sixaxis to dev_is_sixaxis for clarity
Johan Hedberg [Wed, 27 Nov 2013 10:14:32 +0000 (12:14 +0200)]
input: Rename check_sixaxis to dev_is_sixaxis for clarity

10 years agoplugins/sixaxis: Use explicit include paths
Johan Hedberg [Wed, 27 Nov 2013 09:32:36 +0000 (11:32 +0200)]
plugins/sixaxis: Use explicit include paths

10 years agoinput: Add support for handling sixaxis devices
Szymon Janc [Mon, 25 Nov 2013 22:15:52 +0000 (22:15 +0000)]
input: Add support for handling sixaxis devices

This allows to handle incoming connection from unknown devices.
If device happens to be sixaxis input device is created after
SDP was queried and then connection is authorized.

10 years agodevice: Add device_discover_services function
Szymon Janc [Mon, 25 Nov 2013 22:15:51 +0000 (22:15 +0000)]
device: Add device_discover_services function

This will allow to query remote services from plugins for not yet
discovered devices.

10 years agoplugins/sixaxis: Add support for configuring new controllers
Szymon Janc [Mon, 25 Nov 2013 22:15:50 +0000 (22:15 +0000)]
plugins/sixaxis: Add support for configuring new controllers

When new PS3 controller is detected provide it with default adapter
address. Also create new btd_device with proper PNP info if it wasn't
existing yet.

10 years agoplugins/sixaxis: Add initial code for udev handling
Szymon Janc [Mon, 25 Nov 2013 22:15:49 +0000 (22:15 +0000)]
plugins/sixaxis: Add initial code for udev handling

When new device is added plugin will be notified about it.

10 years agoplugins: Add initial code for sixaxis plugin
Szymon Janc [Mon, 25 Nov 2013 22:15:48 +0000 (22:15 +0000)]
plugins: Add initial code for sixaxis plugin

This plugin will be used to associate PS3 controllers.

10 years agoRename adapter_find_device to btd_adapter_find_device
Szymon Janc [Mon, 25 Nov 2013 22:15:47 +0000 (22:15 +0000)]
Rename adapter_find_device to btd_adapter_find_device

Allow this symbol to be exported and usable from external plugins.

10 years agoRename adapter_get_address to btd_adapter_get_address
Szymon Janc [Mon, 25 Nov 2013 22:15:46 +0000 (22:15 +0000)]
Rename adapter_get_address to btd_adapter_get_address

Allow this symbol to be exported and usable from external plugins.

10 years agoRename device_get_uuids to btd_device_get_uuids
Szymon Janc [Mon, 25 Nov 2013 22:15:45 +0000 (22:15 +0000)]
Rename device_get_uuids to btd_device_get_uuids

Allow this symbol to be exported and usable from external plugins.

10 years agoRename device_device_set_name to btd_device_device_set_name
Szymon Janc [Mon, 25 Nov 2013 22:15:44 +0000 (22:15 +0000)]
Rename device_device_set_name to btd_device_device_set_name

Allow this symbol to be exported and usable from external plugins.

10 years agoRename device_set_trusted to btd_device_set_trusted
Szymon Janc [Mon, 25 Nov 2013 22:15:43 +0000 (22:15 +0000)]
Rename device_set_trusted to btd_device_set_trusted

Allow this symbol to be exported and usable from external plugins.

10 years agoRename device_set_temporary to btd_device_set_temporary
Szymon Janc [Mon, 25 Nov 2013 22:15:42 +0000 (22:15 +0000)]
Rename device_set_temporary to btd_device_set_temporary

Allow this symbol to be exported and usable from external plugins.

10 years agoRename adapter_get_device to btd_adapter_get_device
Szymon Janc [Mon, 25 Nov 2013 22:15:41 +0000 (22:15 +0000)]
Rename adapter_get_device to btd_adapter_get_device

Allow this symbol to be exported and usable from external plugins.

10 years agocore: Export some symbols from libbluetooth
Szymon Janc [Mon, 25 Nov 2013 22:15:40 +0000 (22:15 +0000)]
core: Export some symbols from libbluetooth

Those are commonly used and should be available for external plugins.

10 years agocore: Fix protecting from agent callback freeing the agent
Johan Hedberg [Wed, 27 Nov 2013 08:59:53 +0000 (10:59 +0200)]
core: Fix protecting from agent callback freeing the agent

10 years agocore: Fix checking for removed authorization in agent_auth_cb
Johan Hedberg [Wed, 27 Nov 2013 08:59:19 +0000 (10:59 +0200)]
core: Fix checking for removed authorization in agent_auth_cb

10 years agoandroid/socket: Use security level for connect / listen
Andrei Emeltchenko [Tue, 26 Nov 2013 14:05:46 +0000 (16:05 +0200)]
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.

10 years agoandroid/socket: Make profile struct const
Andrei Emeltchenko [Tue, 26 Nov 2013 14:05:45 +0000 (16:05 +0200)]
android/socket: Make profile struct const

We are not supposed to change profile structure, make it const.

10 years agoandroid/haltest: Add uuid autocompletions
Andrei Emeltchenko [Tue, 26 Nov 2013 13:47:05 +0000 (15:47 +0200)]
android/haltest: Add uuid autocompletions

10 years agoandroid/haltest: trivial: Fix typo channle -> channel
Andrei Emeltchenko [Tue, 26 Nov 2013 13:47:04 +0000 (15:47 +0200)]
android/haltest: trivial: Fix typo channle -> channel

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-24-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 11:23:18 +0000 (13:23 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-24-C test

Verify that the IUT (ACP) is able to accept a command to abort a stream.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-23-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 11:15:55 +0000 (13:15 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-23-C test

Verify that the IUT (INT) is able to abort a stream by issuing the
AVDTP_ABORT and reporting the replied confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-22-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 10:20:16 +0000 (12:20 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-22-C test

Verify that the IUT (ACP) is able to accept an AVDTP_SUSPEND_CMD, after
the streaming procedure has been started, by reporting the suspension
and replying the returned confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-21-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 10:17:28 +0000 (12:17 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-21-C test

Verify that the IUT (INT) is able to initiate the suspension of a
streaming procedure, after the streaming procedure has been started, by
issuing the AVDTP_SUSPEND_CMD.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-20-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 09:58:08 +0000 (11:58 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-20-C test

Verify that the IUT (ACP) is able to accept an AVDTP_CLOSE_CMD after the
streaming procedure has been started, by releasing all the resources
associated to the SEP, reporting of the closing and replying the
returned confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-19-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 09:56:33 +0000 (11:56 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-19-C test

Verify that the IUT (INT) is able to initiate the release of a streaming
procedure after the streaming procedure has been started, by issuing the
AVDTP_CLOSE_CMD, releasing all the resources associated to the SEP after
reception of the replied confirmation and reporting the closing.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-18-C test
Luiz Augusto von Dentz [Sun, 24 Nov 2013 13:35:52 +0000 (15:35 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-18-C test

To verify that the IUT (ACP) reports the reception of valid
AVDTP_START_CMD and replies the returned confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-17-C test
Luiz Augusto von Dentz [Sun, 24 Nov 2013 12:33:03 +0000 (14:33 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-17-C test

Verify that the IUT (INT) is able to start a streaming procedure after
the stream establishment is complete, by issuing the AVDTP_START_CMD,
reporting the replied confirmation and streaming packets.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-16-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 15:44:45 +0000 (17:44 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-16-C test

Verify that the IUT (ACP) reports the reception of valid AVDTP_OPEN_CMD
for transport sessions associated to a SEP and replies the returned
confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-15-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 15:37:03 +0000 (17:37 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-15-C test

Verify that the IUT (INT) is able to establish a stream connection to a
previously configured remote SEP by establishing one L2CAP channel
(AVDTP_OPEN_CMD), and reports the related confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-12-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 13:38:41 +0000 (15:38 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-12-C test

Verify that the IUT (ACP) reports the reception of a valid get
configuration command for remote SEP and replies the returned
configuration.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-11-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 13:30:38 +0000 (15:30 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-11-C test

Verify that the IUT (INT) is able to issue a valid get configuration
command for remote SEP and report the replied configuration.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-10-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 13:07:38 +0000 (15:07 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-10-C test

Verify that the IUT (ACP) reports the reception of a valid set
configuration command for remote SEP, and configures the SEP as
requested and replies the returned confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-09-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 13:06:48 +0000 (15:06 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-09-C test

Verify that the IUT (INT) is able to issue a valid set configuration
command for remote SEP and reports the replied confirmation.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-08-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 09:18:32 +0000 (11:18 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-08-C test

Verify that the IUT (ACP) reports the reception of a valid query for
remote SEP capabilities and replies the returned capabilities.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-07-C test
Luiz Augusto von Dentz [Thu, 21 Nov 2013 09:15:01 +0000 (11:15 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-07-C test

Verify that the IUT (INT) is able to issue a valid query for remote SEP
capabilities and reports the replied ones.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-06-C test
Luiz Augusto von Dentz [Mon, 25 Nov 2013 11:49:53 +0000 (13:49 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-06-C test

Verify that the IUT (ACP) reports the reception of a valid stream
discover command and replies the returned list of SEPs and media types.

10 years agounit/AVDTP: Add /TP/SIG/SMG/BV-05-C test
Luiz Augusto von Dentz [Wed, 20 Nov 2013 15:42:48 +0000 (17:42 +0200)]
unit/AVDTP: Add /TP/SIG/SMG/BV-05-C test

Verify that the IUT (INT) is able to issue a valid stream discover command
and report the replied SEPs and media types.

10 years agoandroid/AVDTP: Strip dependencies
Luiz Augusto von Dentz [Wed, 20 Nov 2013 12:30:19 +0000 (14:30 +0200)]
android/AVDTP: Strip dependencies

This strips AVDTP code of any dependency of core and btio to make it
transport agnostic.

10 years agoandroid: Add copy of current AVDTP implemention
Luiz Augusto von Dentz [Mon, 25 Nov 2013 13:59:28 +0000 (15:59 +0200)]
android: Add copy of current AVDTP implemention

These files are not added to any makefile on purpose because they still
have external dependencies.

10 years agosdptool: Make code consistent for SPP record add
Andrei Emeltchenko [Mon, 25 Nov 2013 13:14:45 +0000 (15:14 +0200)]
sdptool: Make code consistent for SPP record add

Move freeing to the end of the function like it is done for other
records.

10 years agosdptool: Fix memory leaks creating PBAP record
Andrei Emeltchenko [Mon, 25 Nov 2013 13:14:44 +0000 (15:14 +0200)]
sdptool: Fix memory leaks creating PBAP record

10 years agosdptool: Fix memory leaks creating OPP record
Andrei Emeltchenko [Mon, 25 Nov 2013 13:14:43 +0000 (15:14 +0200)]
sdptool: Fix memory leaks creating OPP record

10 years agoandroid/socket: Add error printing possible close() failure
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:53 +0000 (15:08 +0200)]
android/socket: Add error printing possible close() failure

10 years agoandroid/socket: Use default sec_level for listen
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:52 +0000 (15:08 +0200)]
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.

10 years agoandroid/hal-utils: Fix possible NULL pointer dereference
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:51 +0000 (15:08 +0200)]
android/hal-utils: Fix possible NULL pointer dereference

10 years agoandroid/socket: Refactor socket send_fd function
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:50 +0000 (15:08 +0200)]
android/socket: Refactor socket send_fd function

Make code cleaner and initialize local cmsg buffer to zeroes.

10 years agoandroid/hal-sock: Print bdaddr on connect
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:49 +0000 (15:08 +0200)]
android/hal-sock: Print bdaddr on connect

10 years agoandroid/socket: Support listen() with supplied chan number
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:48 +0000 (15:08 +0200)]
android/socket: Support listen() with supplied chan number

No profile is assigned in this case. There is a possibility to use
Serial Port Profile.

10 years agoandroid/socket: Add SPP SDP record
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:47 +0000 (15:08 +0200)]
android/socket: Add SPP SDP record

10 years agoandroid/socket: Add PBAP SDP record
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:46 +0000 (15:08 +0200)]
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

10 years agoandroid/socket: Add SPP uuid to profile table
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:45 +0000 (15:08 +0200)]
android/socket: Add SPP uuid to profile table

10 years agoandroid/socket: Add MAS uuid to profile table
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:44 +0000 (15:08 +0200)]
android/socket: Add MAS uuid to profile table

10 years agoandroid/socket: Add OPP SDP record
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:43 +0000 (15:08 +0200)]
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

10 years agoandroid/socket: Add general service create/remove function
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:42 +0000 (15:08 +0200)]
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.

10 years agoandroid/socket: Close file descriptor after sending
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:41 +0000 (15:08 +0200)]
android/socket: Close file descriptor after sending

10 years agoandroid/socket: Send connect signal to Android framework
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:40 +0000 (15:08 +0200)]
android/socket: Send connect signal to Android framework

Android framework expects connect signal to be sent when
remote device is connected.

10 years agoandroid/socket: Send RFCOMM channel to framework
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:39 +0000 (15:08 +0200)]
android/socket: Send RFCOMM channel to framework

Framework expects channel to be send.

10 years agoandroid/socket: Implement HAL connect call
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:38 +0000 (15:08 +0200)]
android/socket: Implement HAL connect call

HAL connect uses similar event handlers like listen call.

10 years agoandroid/socket: Parse SDP response and connect
Andrei Emeltchenko [Mon, 25 Nov 2013 13:08:37 +0000 (15:08 +0200)]
android/socket: Parse SDP response and connect

Parse SDP response, find RFCOMM channel and connect.

10 years agoclient: Add paired-devices command to bluetoothctl
Sebastian Chlad [Wed, 20 Nov 2013 20:21:52 +0000 (21:21 +0100)]
client: Add paired-devices command to bluetoothctl

Paired-devices command lists only paired devices

10 years agoclient: Fix handling of (G_IO_IN | G_IO_HUP) input case
Philip Withnall [Fri, 22 Nov 2013 12:47:42 +0000 (12:47 +0000)]
client: Fix handling of (G_IO_IN | G_IO_HUP) input case

If running bluetoothctl as a subprocess from another process, and piping
input to it, it’s possible for the stdin pipe to be closed by the parent
process while there’s still data pending in its buffer. This results in
input handler callbacks with condition (G_IO_IN | G_IO_HUP). All of the
pending input should be handled before closing bluetoothctl.

10 years agoandroid/bluetooth: Fix memory leak
Andrei Emeltchenko [Fri, 22 Nov 2013 14:21:12 +0000 (16:21 +0200)]
android/bluetooth: Fix memory leak

10 years agoandroid/pics: Add PTS PICS for DID
Jakub Tyszkowski [Fri, 22 Nov 2013 10:47:40 +0000 (11:47 +0100)]
android/pics: Add PTS PICS for DID

PTS PICS for DID, targeting Android 4.4.

10 years agoandroid/pics: Add PTS PICS for PAN
Jakub Tyszkowski [Fri, 22 Nov 2013 10:47:38 +0000 (11:47 +0100)]
android/pics: Add PTS PICS for PAN

PTS PICS for PAN, targeting Android 4.4.

10 years agoandroid/hal-bluetooth: Use static memory for enum convertion
Szymon Janc [Mon, 25 Nov 2013 11:32:00 +0000 (12:32 +0100)]
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.

10 years agoandroid/haltest: Zero initialize cmsg buffer
Andrei Emeltchenko [Thu, 21 Nov 2013 14:23:31 +0000 (16:23 +0200)]
android/haltest: Zero initialize cmsg buffer

10 years agoandroid/ipc: Zero initialize cmsg buffer
Andrei Emeltchenko [Thu, 21 Nov 2013 14:23:30 +0000 (16:23 +0200)]
android/ipc: Zero initialize cmsg buffer

This fixes valgrind warnings:
...
Syscall param sendmsg(msg.msg_control) points to uninitialised byte(s)
...

10 years agoandroid/a2dp: Cleanup devices on unregister
Luiz Augusto von Dentz [Wed, 20 Nov 2013 09:39:54 +0000 (11:39 +0200)]
android/a2dp: Cleanup devices on unregister

This cleanup any existing devices in bt_a2dp_unregister

10 years agocore: Fix missing NULL check for msg
Johan Hedberg [Thu, 21 Nov 2013 07:53:40 +0000 (09:53 +0200)]
core: Fix missing NULL check for msg

device_request_disconnect can be called with msg being NULL, however
g_dbus_send_reply cannot. Therefore, add a check for msg before calling
g_dbus_send_reply.

10 years agoandroid/socket: Implement socket connect HAL method
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:27 +0000 (12:24 +0200)]
android/socket: Implement socket connect HAL method

First step is to query remote device for RFCOMM channel.

10 years agoandroid/socket: Notify channel to Android framework
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:26 +0000 (12:24 +0200)]
android/socket: Notify channel to Android framework

Android framework expects to receive channel number as int.

10 years agoandroid/socket: Send accept signal to Android framework
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:25 +0000 (12:24 +0200)]
android/socket: Send accept signal to Android framework

Android expects to get accept signal over file descriptor which was
set during listen HAL call.

10 years agoandroid/socket: Implement RFCOMM events
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:24 +0000 (12:24 +0200)]
android/socket: Implement RFCOMM events

Copy data from RFCOMM socket to Android framework. Consider splice
in the future.

10 years agoandroid/socket: Implement Android RFCOMM stack events
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:23 +0000 (12:24 +0200)]
android/socket: Implement Android RFCOMM stack events

Handle events from Android framework. Write everything to real RFCOMM
socket. Consider splice() in the future.

10 years agoandroid/socket: Implement socket accepted event
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:22 +0000 (12:24 +0200)]
android/socket: Implement socket accepted event

When we get accepted event we create rfcomm slot and start listening
for events from Android framework and from RFCOMM real socket.

10 years agoandroid/socket: Implement listen on RFCOMM socket
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:20 +0000 (12:24 +0200)]
android/socket: Implement listen on RFCOMM socket

Handle HAL socket listen call. Create RFCOMM socket and wait for events.

10 years agoandroid/socket: Add get RFCOMM default channel
Andrei Emeltchenko [Wed, 20 Nov 2013 10:24:19 +0000 (12:24 +0200)]
android/socket: Add get RFCOMM default channel

RFCOMM default channel is the same like in other BlueZ code, it is
defined in src/profile.c

10 years agoandroid/hal-pan: Fix order of event handler registration
Ravi kumar Veeramally [Tue, 19 Nov 2013 21:24:18 +0000 (23:24 +0200)]
android/hal-pan: Fix order of event handler registration

IPC message handler determines handler offset with
opcode = msg->opcode - HAL_MINIMUM_EVENT. But here order is misplaced.

10 years agoandroid/hal-a2dp: Fix expected size of A2DP events
Ravi kumar Veeramally [Tue, 19 Nov 2013 20:59:23 +0000 (22:59 +0200)]
android/hal-a2dp: Fix expected size of A2DP events

10 years agoandroid: Fix expected size of hal_ev_ssp_request
Johan Hedberg [Tue, 19 Nov 2013 20:35:47 +0000 (22:35 +0200)]
android: Fix expected size of hal_ev_ssp_request

10 years agoandroid/build: Add PICS files to EXTRA_DIST
Johan Hedberg [Tue, 19 Nov 2013 16:34:19 +0000 (18:34 +0200)]
android/build: Add PICS files to EXTRA_DIST

10 years agoandroid/pics: Fix line lengths
Johan Hedberg [Tue, 19 Nov 2013 16:33:10 +0000 (18:33 +0200)]
android/pics: Fix line lengths

10 years agoandroid: Add PTS PICS for HID
Jakub Tyszkowski [Tue, 19 Nov 2013 14:36:15 +0000 (15:36 +0100)]
android: Add PTS PICS for HID

PTS PICS for HID, targeting Android 4.4.

10 years agoandroid: Add PTS PICS for GAP
Jakub Tyszkowski [Tue, 19 Nov 2013 14:36:14 +0000 (15:36 +0100)]
android: Add PTS PICS for GAP

PTS PICS for GAP, targeting Android 4.4.

10 years agoandroid/hal-bluetooth: Remove not needed check in get_adapter_property
Szymon Janc [Tue, 19 Nov 2013 15:51:54 +0000 (16:51 +0100)]
android/hal-bluetooth: Remove not needed check in get_adapter_property

Properties types are verified on daemon side and proper error is
returned on wrong type. No need to double check that on HAL side.

10 years agoandroid/hal-bluetooth: Remove not needed check in set_adapter_property
Szymon Janc [Tue, 19 Nov 2013 15:51:53 +0000 (16:51 +0100)]
android/hal-bluetooth: Remove not needed check in set_adapter_property

Properties types are verified on daemon side and proper error is
returned on wrong type. No need to double check that on HAL side.

10 years agoandroid/hal-bluetooth: Handle dut mode receive event
Szymon Janc [Tue, 19 Nov 2013 15:51:52 +0000 (16:51 +0100)]
android/hal-bluetooth: Handle dut mode receive event

Pass received data to callback if it is present.

10 years agoandroid/hal-bluetooth: Remove not needed __func__ from debug print
Szymon Janc [Tue, 19 Nov 2013 15:51:51 +0000 (16:51 +0100)]
android/hal-bluetooth: Remove not needed __func__ from debug print

DBG macro already adds function name to print output.