OSDN Git Service
Marcel Holtmann [Wed, 23 Jul 2014 08:42:33 +0000 (10:42 +0200)]
tools: Fix usage for del-device command
Marcel Holtmann [Tue, 22 Jul 2014 19:23:56 +0000 (21:23 +0200)]
monitor: Add support for decoding Read Local Supported Codecs
Sebastian Chlad [Tue, 22 Jul 2014 08:39:29 +0000 (10:39 +0200)]
android/pts: Initial PTS docs for SPP
PTS tests done on Android 4.4.4 and PTS 5.2
Jakub Tyszkowski [Mon, 21 Jul 2014 13:23:40 +0000 (15:23 +0200)]
android/tester-ng: Minor title fix for core cases
Now with more space for test case's title in the summary, we can use full
"Bluetooth" for all core bluetooth interface test cases.
Jakub Tyszkowski [Mon, 21 Jul 2014 13:23:39 +0000 (15:23 +0200)]
shared/tester: Increase space for test case title
This makes more space for case's title in the summary, and still
retains 80 chars boundary. This fixes column alignment when using
long case titles i.e. in new android-tester.
Andrei Emeltchenko [Tue, 22 Jul 2014 07:42:53 +0000 (10:42 +0300)]
android/client: Rearrange header includes
Use proper order for header includes in if-audio HAL client
Andrei Emeltchenko [Mon, 21 Jul 2014 09:53:03 +0000 (12:53 +0300)]
android/ipc: Rename connect_sco to get_fd
SCO get connected through handsfree HAL and Audio SCO HAL only need to
get SCO socket fd.
Andrei Emeltchenko [Mon, 21 Jul 2014 11:05:16 +0000 (14:05 +0300)]
android/client: Rearrange headers include
Grzegorz Kolodziejczyk [Fri, 18 Jul 2014 11:59:56 +0000 (13:59 +0200)]
android/pts: Update PTS files for HID
PICS and PIXITs updated to PTS 5.2. Regression done for Android
4.4.4.
Sebastian Chlad [Mon, 21 Jul 2014 07:54:15 +0000 (09:54 +0200)]
android/pts: Interim PTS tests results for RFCOMM
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:29 +0000 (09:40 +0200)]
android/tester: Remove old bluetooth core test cases
This removes few last bluetooth cases from the old tester.
All cases were ported to new testing framework.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:28 +0000 (09:40 +0200)]
android/tester-ng: Add more bonding cases
This adds more cases for bond, bond canceling and bond removal.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:27 +0000 (09:40 +0200)]
android/tester-ng: Add ssp confirmation cases
Needed actions were added to properly execute spp procedure. Also
callback data was extended to verify incomming ssp variant, and
action data was extended to pass ssp accept parameters.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:26 +0000 (09:40 +0200)]
android/tester-ng: Add wrong PIN reply test case
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:25 +0000 (09:40 +0200)]
android/tester-ng: Add BREDR pairing with pin test case
This also adds some actions for setting pin the emulated device and
for calling bonding api of bluetooth core.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:24 +0000 (09:40 +0200)]
android/tester-ng: Add pin request and bond state callbacks
To fully verify data passed by these callbacks we reuse existing
device properties verification mechanism. For this, callback argumenents
are repacked to properties array for further verification.
Those are verified against values passed to the callback step definition
macro just like with any other definition of callback step in which
we get device properties.
An alternative would be to extend 'bt_callback_data' struct and add new
fields for bdaddr, name, class of device and other properties, that we
get in callbacks as sepparate values and not as list of props.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:23 +0000 (09:40 +0200)]
android/tester-ng: Add missing check for callback status
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:22 +0000 (09:40 +0200)]
android/tester-ng: Improve variable's names
Some variables are specific to emulator device type and remote device type.
This patch makes names more descriptive.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:21 +0000 (09:40 +0200)]
android/tester-ng: Improve callback defining makro
This makes CALLBACK_DEVICE_PROPS and CALLBACK_DEVICE_FOUND use more
generic CALLBACK_PROPS makro.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:20 +0000 (09:40 +0200)]
android/tester-ng: Improve result print
It might be usefull to print if test involves LE or BREDR adapter and
remotes. Test case title length had to be reduced for better results
format.
Jakub Tyszkowski [Mon, 21 Jul 2014 07:40:19 +0000 (09:40 +0200)]
android/tester-ng: Allow test framework user to choose emu type
This allows to set emulated adapter type for each test case in place
where tests are defined. Previously this was hardcoded in the framework.
Andrei Emeltchenko [Fri, 18 Jul 2014 14:35:30 +0000 (17:35 +0300)]
android/hal-audio: Remove unneeded check
rsp_len cannot be NULL here because of NULL check in the beginning of
the function.
Andrei Emeltchenko [Fri, 18 Jul 2014 14:35:29 +0000 (17:35 +0300)]
android/hal-sco: Remove unneeded check
rsp_len cannot be NULL since it checked for NULL in the beginning of the
function.
Johan Hedberg [Fri, 18 Jul 2014 12:35:18 +0000 (15:35 +0300)]
core: Enable AlwaysPairable on old kernels which need it
Johan Hedberg [Fri, 18 Jul 2014 12:19:19 +0000 (15:19 +0300)]
core: Bundle pairable and discoverable together
When AlwaysPairable is not set it makes sense to simplify our modes and
bind the pairable and discoverable settings together. This means that
all three of connectable, discoverable and pairable are either on or
off.
Johan Hedberg [Fri, 18 Jul 2014 12:22:28 +0000 (15:22 +0300)]
core: Fix triggering PairableTimeout signal only when it changes
Johan Hedberg [Fri, 18 Jul 2014 12:18:43 +0000 (15:18 +0300)]
core: Fix trying to enable discoverable with a timeout
Johan Hedberg [Fri, 18 Jul 2014 12:13:22 +0000 (15:13 +0300)]
core: Move always_pairable check into adapter_set_pairable()
Johan Hedberg [Fri, 18 Jul 2014 12:11:56 +0000 (15:11 +0300)]
core: Disable connectable upon init if kernel whitelist is not in use
Johan Hedberg [Fri, 18 Jul 2014 12:04:14 +0000 (15:04 +0300)]
core: Add convenience API to check for available default agent
Szymon Janc [Fri, 18 Jul 2014 12:11:55 +0000 (14:11 +0200)]
android/tester-ng: Fix timestamp property type
This type is unspecified in HAL API and we currently use uint32_t
for it. This also fix build error on 32bit machines.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:19 +0000 (12:48 +0300)]
android/hal-sco: Fix error code printing
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:18 +0000 (12:48 +0300)]
android/hal-sco: Fix leaving open socket
Close accepted socket always after poll loop.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:17 +0000 (12:48 +0300)]
android/hal-audio: Fix leaving open socket
When getting out of the poll loop we shall close socket always.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:16 +0000 (12:48 +0300)]
android/hal-sco: Fix incorrect assignment
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:15 +0000 (12:48 +0300)]
android/hal-sco: Defer SCO connection to write()
Do not return error when opening output stream if SCO is not connected
yet, we will check it later with actual out_write().
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:14 +0000 (12:48 +0300)]
android/hal-sco: Get SCO audio fd on demand
When SCO fd is not known try to get it from the daemon. SCO is
established via handsfree HAL independently from Audio HAL.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:13 +0000 (12:48 +0300)]
android/hal-sco: Add stream synchronization
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:12 +0000 (12:48 +0300)]
android/hal-sco: Choose buffer size
For 8k choose buffer size 576 which is multiple from 48 and 64.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:11 +0000 (12:48 +0300)]
android/hal-sco: Skip resampling for input of 8k
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:10 +0000 (12:48 +0300)]
android/hal-sco: Skip resampling for output stream with 8k
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:09 +0000 (12:48 +0300)]
android/hal-sco: Implement read
Add read and resampling from 8000 to 44100.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:08 +0000 (12:48 +0300)]
android/hal-sco: Fix memory leak
Release resampler on exit.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:07 +0000 (12:48 +0300)]
android/hal-sco: Make debug more readable
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:06 +0000 (12:48 +0300)]
android/hal-sco: Use global sco file descriptor
Android may open input/output stream independently so we use global sco
file descriptor and mutexes.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:05 +0000 (12:48 +0300)]
android/hal-sco: Check file descriptor >= 0
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:04 +0000 (12:48 +0300)]
android/hal-sco: Implement open input stream
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:03 +0000 (12:48 +0300)]
android/hal-sco: Make use of config parameter
Use config parameter when opening output stream.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:02 +0000 (12:48 +0300)]
android/hal-sco: Add SCO packet cache
SCO cached is used when Android writes with packet sizes which cannot
fit to 48 bytes SCO frames. Remaining frames are cached and written next
time Android perform out->write().
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:01 +0000 (12:48 +0300)]
android/hal-sco: Move mtu assignment to open_stream()
mtu shall be assigned when opening stream to be logically correct.
Andrei Emeltchenko [Fri, 18 Jul 2014 09:48:00 +0000 (12:48 +0300)]
android/hal-sco: Use nanosleep for SCO synchronization
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:21 +0000 (11:50 +0200)]
android/tester: Remove old test cases
Those tests are now in the newer tester.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:20 +0000 (11:50 +0200)]
android/tester-ng: Add remote device set property fail cases
Those set property requests should fail as they request to set remotes
adapter properties.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:19 +0000 (11:50 +0200)]
android/tester-ng: Add set remote friendly name success case
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:18 +0000 (11:50 +0200)]
android/tester-ng: Add get remote property failing cases
Those properties requests should fails as those are adapter specific
ones and does not apply to remote devices.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:17 +0000 (11:50 +0200)]
android/tester-ng: Add get remote props cases
This patch also introduces bt_action_data for passing arguments to HAL
api calls. So far one argument was enough but now there's need for more.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:16 +0000 (11:50 +0200)]
android/tester-ng: Replace action result with status
Action (HAL api call) result is always status or file descriptor.
Integer value is enough to hold both so it replaced the truct.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:15 +0000 (11:50 +0200)]
android/tester-ng: Add get remote properties case
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:14 +0000 (11:50 +0200)]
android/tester-ng: Add remote device found case
This patch adds first test case that requires remote emulated device to be
discovered. New action step was added to activate this device on demand.
Jakub Tyszkowski [Fri, 18 Jul 2014 09:50:13 +0000 (11:50 +0200)]
emulator: Add flags param to advertise enabling function
This allows to pass additional parameter describing wheter to set
flags parameter in advertising data.
This is needed to make device discoverable.
Grzegorz Kolodziejczyk [Thu, 17 Jul 2014 10:54:18 +0000 (12:54 +0200)]
android/pts: Update PTS files for HFP
PICS and PIXITs updated to PTS 5.2. Regression done for Android
4.4.4.
Sebastian Chlad [Thu, 17 Jul 2014 11:04:32 +0000 (13:04 +0200)]
android/build: Add rctest tool to Android build
Marcin Kraglak [Thu, 17 Jul 2014 08:42:50 +0000 (10:42 +0200)]
android/gatt: Fix incorrect status in read characteristic cb
Pass correct status to upper layer.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:49 +0000 (10:42 +0200)]
android/gatt: Send proper status of read descriptor callback
Pass proper status to upper layer.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:48 +0000 (10:42 +0200)]
android/gatt: Add GATT_PERM_NONE define
Use this permission if no read and write is allowed. It is now set
in service change characteristic.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:47 +0000 (10:42 +0200)]
android/gatt: Fix read responses with 0 length value
Attribute's value length can be 0, so fill read response and send.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:46 +0000 (10:42 +0200)]
android/gatt: Fix check for permissions error
If error is returned from check_device_permissions, fill response
data and return. In case of read errors we didn't send error response.
Zero length data was send instead.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:45 +0000 (10:42 +0200)]
android/gatt: Fix searching primary services by uuids
Return all instances of services. It is not proper behaviour to
return only one instance of service with same uuid.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:44 +0000 (10:42 +0200)]
attrib: Fix discovering descriptors
Discover all attributes in given range. In same cases we ommited
last attribute in range.
Marcin Kraglak [Thu, 17 Jul 2014 08:42:43 +0000 (10:42 +0200)]
android/gatt: Fix service class id of built in gatt services
Johan Hedberg [Fri, 18 Jul 2014 09:01:47 +0000 (12:01 +0300)]
doc/test-coverage: Update mgmt-tester test count
Johan Hedberg [Fri, 18 Jul 2014 08:59:44 +0000 (11:59 +0300)]
tools/mgmt-tester: Add non-pairable SSP acceptor test case
Johan Hedberg [Fri, 18 Jul 2014 08:59:22 +0000 (11:59 +0300)]
tools/mgmt-tester: Fix calling bthost_set_auth_req() twice
Johan Hedberg [Fri, 18 Jul 2014 08:40:14 +0000 (11:40 +0300)]
tools/mgmt-tester: Add non-pairable legacy pairing acceptor test case
Johan Hedberg [Fri, 18 Jul 2014 08:32:59 +0000 (11:32 +0300)]
tools/mgmt-tester: Add BR/EDR Legacy non-pairable initiator test case
Johan Hedberg [Fri, 18 Jul 2014 07:52:39 +0000 (10:52 +0300)]
core: Make pairable mode dependent on the existence of a default agent
This patch updates the adapter code to only enable pairable mode when
there is a default agent available. A new main.conf option called
AlwaysPairable is also introduced to allow keeping the old behavior,
however the default is the new behavior (i.e. this option defaults to
FALSE).
Johan Hedberg [Fri, 18 Jul 2014 07:38:43 +0000 (10:38 +0300)]
core: Expose adapter API to enable/disable pairable mode
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:53 +0000 (10:29 +0200)]
android/tester-ng: Add cancel discovery cases
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:52 +0000 (10:29 +0200)]
android/tester-ng: Add start discovery success cases
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:51 +0000 (10:29 +0200)]
android/tester-ng: Use test case independent naming for props
This patch abstracts out data from the specific test cases. Every data
that is sent through the hal (i.e. properties) and then the result is
verified is a test data thus uses 'test_prop_<dataname>' convention.
Data that is retrieved from the deamon and is adapter's default settings
use 'emu_prop_<dataname>' notation.
Data name now represents it's content and is no longer bound to specific
test case thus can be reused. Its also easier to actually see what the
test case do without browsing through its data set.
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:50 +0000 (10:29 +0200)]
android/tester-ng: Use array of statics instead of case pointers
This is yet another macro that hides the test implementation details and
shortens the amount of code that needs to be written for each test case.
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:49 +0000 (10:29 +0200)]
android/tester-ng: Add test declaration helper macro
This replaces test cases declaration with simplier macro call.
Jakub Tyszkowski [Thu, 17 Jul 2014 08:29:48 +0000 (10:29 +0200)]
android/tester-ng: Use action and callback defining macros
This significantly shortens the action definitions.
Sebastian Chlad [Thu, 17 Jul 2014 08:17:06 +0000 (10:17 +0200)]
android/pts: Update PTS files for MAP
Regression tests for MAP on PTS 5.2 and Android 4.4.4.
Johan Hedberg [Thu, 17 Jul 2014 12:47:30 +0000 (15:47 +0300)]
tools/mgmt-tester: Update non-pairable pairing initiator test
Latest kernels allow pairing initiation while not parirable, so update
the corresponding test.
Andrei Emeltchenko [Wed, 16 Jul 2014 12:17:30 +0000 (15:17 +0300)]
shared/gatt: Fix NULL pointer dereference on destroy
This patch adds pointer check to gatt_db_destroy allowing user to call
it with NULL pointer. This follow convention used in shared code for
destroy functions. This fix following android bluetoothd crash in a case
crypto failed to initialize.
...
I/ProbeModule(24651): insmod_by_dep: parse base black list error -1
E/ProbeModule(24651): insmod_by_dep: cannot find module's dependency
info: [net-pf-38]
I/bluetoothd(24639): bluetoothd[24640]: gatt: Failed to setup crypto
...
I/DEBUG (16237): *** *** *** *** *** *** *** *** *** *** *** *** ***
*** *** ***
I/DEBUG (16237): Build fingerprint:
'Intel/hsb/hsb:4.4.2/KOT49H/eng.android.
20140514.123328:eng/test-keys'
I/DEBUG (16237): Revision: '0'
I/DEBUG (16237): pid: 24640, tid: 24640, name: bluetoothd-main >>>
/system/bin/bluetoothd-main <<<
I/DEBUG (16237): signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr
00000004
...
I/DEBUG (16237): stack:
I/DEBUG (16237):
ff81a9dc ff81aa14 [stack]
I/DEBUG (16237):
ff81a9e0 00000000
I/DEBUG (16237):
ff81a9e4 f75c2e06 /system/lib/libc.so
(vsyslog+6)
I/DEBUG (16237):
ff81a9e8 f77c0cd8
/system/bin/bluetoothd-main
I/DEBUG (16237):
ff81a9ec f778692c
/system/bin/bluetoothd-main (gatt_db_destroy+12)
I/DEBUG (16237): #00
ff81a9f0 00000003
I/DEBUG (16237):
ff81a9f4 f77865c0
/system/bin/bluetoothd-main (gatt_db_service_destroy)
I/DEBUG (16237):
ff81a9f8 f7784709
...
Sebastian Chlad [Tue, 15 Jul 2014 14:20:56 +0000 (16:20 +0200)]
android/pts: Update PTS files for HSP
Re-run PTS tests for HSP on PTS 5.2 and Android 4.4.4
Sebastian Chlad [Tue, 15 Jul 2014 12:51:44 +0000 (14:51 +0200)]
android/pts: Update PTS files for AVRCP
Regression test round using PTS 5.2 and Android 4.4.4
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:59 +0000 (10:24 +0200)]
android/tester: Remove old cases
Those were already reimplemented using newer testing framework.
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:58 +0000 (10:24 +0200)]
android/tester-ng: Add set scan mode none succes case
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:57 +0000 (10:24 +0200)]
android/tester-ng: Add get properties success cases
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:56 +0000 (10:24 +0200)]
android/tester-ng: Add set scan mode success case
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:55 +0000 (10:24 +0200)]
android/tester-ng: Add various property set fail cases
These cases should fail as they are read only props.
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:54 +0000 (10:24 +0200)]
android/tester-ng: Add get bdaddr and bdname success cases
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:53 +0000 (10:24 +0200)]
android/tester-ng: Verify action results also for success case
Case when we were expecting fail as action result but we got success was
not caught.
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:52 +0000 (10:24 +0200)]
android/tester-ng: Set proper callback count
This was a missing piece after fixing the callback count verifying
routine.
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:51 +0000 (10:24 +0200)]
android/tester-ng: Fix for not checking callback count in step
If no callback count was set in the step, test passed despite valid properties
still waiting to be verified.
Jakub Tyszkowski [Tue, 15 Jul 2014 08:24:50 +0000 (10:24 +0200)]
android/tester-ng: Use loop for adding cases to the queue
It will be simplier to add new cases.
Johan Hedberg [Wed, 16 Jul 2014 12:55:57 +0000 (15:55 +0300)]
core: Add non-temporary BR/EDR devices to the kernel whitelist
We want to be able to accept connections from all non-temporary devices.
We should pass these devices kernels that support the BR/EDR whitelist
(through the Add Device mgmt command).
Johan Hedberg [Wed, 16 Jul 2014 12:52:28 +0000 (15:52 +0300)]
core: Bind connectable mode to discoverable for kernel connection control
When the kernel supports the BR/EDR whitelist we don't need to always be
connectable in order to receive incoming connections. Therefore, bind
the connectable mode to the discoverable mode whenever kernel connection
control is supported.
To avoid unnecessary mgmt and HCI commands disabling discoverable is
simply done by disabling connectable as it has the effect of disabling
both settings.