History log of /system/bt/service/daemon.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
0a0d3932136995a722cc125ef920679113d8ce0f 20-Nov-2015 Arman Uguray <armansito@google.com> service: Make Adapter mockable.

Turned the Adapter class into an abstract interface so that we
can inject a mock Adapter in tests where there is an Adapter dependency
but where we don't care about side-effects/stack-calls created from the
Adapter.

Bug: 25744656

Change-Id: Ibf7dd9a4cc1008cbb36e60f7b87cfcb4ef2bd5d8
/system/bt/service/daemon.cpp
e415c050edbb2710e8807dd2602c851412953268 23-Sep-2015 Scott James Remnant <keybuk@google.com> Rename IPCHandlerUnix to IPCHandlerLinux

Since it relies on the Linux-specific sequential packet socket type,
rename the "Unix" IPC Handler to "Linux".

Change-Id: I04c4d6d3f73061099ebffb1ee3adfd0a20430dd7
/system/bt/service/daemon.cpp
9ded7b6175825afdac0e2cebef8755e4d7b03103 01-Sep-2015 Arman Uguray <armansito@google.com> service: Add hal::BluetoothGattInterface

Added hal::BluetoothGattInterface which is a C++ wrapper around the
HAL Bluetooth GATT interfaces. This follows the current pattern of hal/*
wrappers and is meant to be fakeable.

Bug: 23395353
Change-Id: Ib11afba9fe2f4632591d5db384edf32ca788bf2c
/system/bt/service/daemon.cpp
d6a4b0c950f44d3eab34825880d26c19e362d22b 14-Aug-2015 Arman Uguray <armansito@google.com> service: Replace CoreStack with Adapter

This CL removes the CoreStack class. Code that depended on a CoreStack instance
now depend on Adapter and hal::BluetoothInterface instead.

Bug: 23169364
Change-Id: Ide008cc7d3f9e74656f6bfa4df2dfee511e55b90
/system/bt/service/daemon.cpp
b2286f386e20a45b5f19a199d0981f4952216fa3 06-Aug-2015 Arman Uguray <armansito@google.com> service: Add IPCHandlerBinder

This CL integrates Binder IPC into the daemon. This introduces
IPCHandlerBinder and BluetoothBinderServer which is the Binder server
proxy for IBluetooth. A new command-line switch is introduced to
optionally disable Binder on platforms that do not use it.

BluetoothBinderServer currently does not fully implement any of the IPC
calls and consists of stubs.

Bug: 22743677
Change-Id: I3e4ba7a3211898bab0c9c8061f4e4db3854711ed
/system/bt/service/daemon.cpp
e0d08c9fecdf92c386b52375501a306c8f67d63e 05-Aug-2015 Arman Uguray <armansito@google.com> service: Clean up IPC shutdown and add unit tests

This CL reworks the IPCHandlerUnix shutdown routine to be more robust
and adds a test suite for the basic thread creation and shutdown sanity.

Bug: 22532180
Change-Id: I22d119d6514f2ceb1460c0925b4e92b71ec87e06
/system/bt/service/daemon.cpp
f8881fee3d08cb50896b22adc0841223694d51d2 04-Aug-2015 Arman Uguray <armansito@google.com> service: Add Mock support for Daemon and CoreStack

This patch turns the Daemon and CoreStack classes into abstract
interfaces. Mock and real implementations are implemented in special
subclasses and obtained via a factory method. Other test implementations
(e.g. stub) can be provided in the future.

Bug: 22532180
Change-Id: Ic3000518e5cef1c867dd803cd0bba6aab49dc596
/system/bt/service/daemon.cpp
c6760d82357f46943406c579f5b1c291a20afdeb 31-Jul-2015 Ian Coolidge <icoolidge@google.com> Provide --android-ipc-socket-suffix.

This allows Android init to create a socket
for the service, and have consolidated access control.

Android init creates the socket and passes the FD through
an environment variable, so we must use OSI to decode it.

Bug: 22807533
Change-Id: I7ec0a14b8f3b44277ce99faad68623d6691f7863
/system/bt/service/daemon.cpp
fe65fb7978bc9257a36d1e5eae59c5f412dbdb49 25-Jul-2015 Arman Uguray <armansito@google.com> service: Refactor IPC and singletons

This CL makes the following major refactors to the system service code:

1. A new global Daemon object is introduced, which manages the main event
loop and all other subsystems of the Bluetooth daemon. This object is the only
singleton class and initializes and owns everything else.

2. Everything that was a singleton and/or was initialized directly in main.cpp
is now a) no longer a singleton; b) now initialized and owned by the global
Daemon instance.

3. All of the Chromecast specific IPC code has been moved into the ipc/
subdirectory. This directory is meant for everything that is IPC related,
paving the way for enabling multiple IPC systems (domain-socket based, Binder
based, etc) simultaneously in the future. Main changes to the Chromecast IPC
code are:

a. All files and classes have been renamed to reflect the
UNIX-domain-socket-specific nature of the IPC mechanism.

b. The code no longer hogs up the main thread while listening for
connections. All of this logic has been moved to a dedicated thread with
its own MessageLoopForIO, so that it can use the built-in mechanisms for
polling on client sockets in the future.

Bug: 22532180
Change-Id: I42db06dba6cff3bc8f8101a1ea2b6787a69409fd
/system/bt/service/daemon.cpp