Commit Graph

7294 Commits

Author SHA1 Message Date
Krzysztof Wilk 8621d36c15 dbus: Define Siri DBUS Interface 2013-12-18 00:07:47 -06:00
Krzysztof Wilk 203409a25b doc: Add Siri API 2013-12-18 00:07:47 -06:00
Denis Kenzior fc98985d14 AUTHORS: Mention Andrew's contributions 2013-12-05 03:50:05 -06:00
Andrew Earl e0aeebae0a hfp: Add Voice Recognition flag to BRSF 2013-12-05 03:45:48 -06:00
Denis Kenzior 7c7cdd8759 he910: tweak initialization logic 2013-11-26 16:25:48 -06:00
Denis Kenzior 85cdacb509 netreg: Turn off CIEV indications other than rssi 2013-11-26 16:25:03 -06:00
Denis Kenzior 3722e626f3 AUTHORS: Mention Slava's contributions 2013-11-26 15:33:08 -06:00
Slava Monich a7ba6d1e9e mbpi: Provision mmsc and message_proxy 2013-11-26 15:32:03 -06:00
Denis Kenzior 9b224fff79 hfp_ag_bluez5: Try to support non-phone hardware
For devices which are not 'real' phone modems, the voicecall
initialization can happen outside of the pre-sim state.  In this case
the voicecall atom detection logic fails.  Try to detect the voicecall
atom separately, and register the profile if the SIM atom is already
present and in state 'READY'.

For all other cases, the previous logic still applies.
2013-11-25 11:33:57 -06:00
Denis Kenzior 06598ef47c udevng: Add he910 detection logic 2013-11-25 10:55:59 -06:00
Denis Kenzior 6e52f03f64 plugins: Add initial Telit he910 driver 2013-11-25 10:55:59 -06:00
Denis Kenzior 8440f77f9a build: Always build the connman plugin
It is not related to BLUEZ 4 support
2013-11-25 10:55:59 -06:00
Bastien Nocera 7a6da06f27 gdbus: Fix trying to remove already removed sources
When we return FALSE from idle handlers, the source is removed.
This will be causing warnings in glib 2.40.

See https://bugzilla.gnome.org/show_bug.cgi?id=710724
2013-11-11 01:06:19 -08:00
Marcel Holtmann 9be2fb1b10 Release 1.13 2013-11-08 00:34:09 -08:00
Denis Kenzior 0aeeaefdce mbm: Fix segfault with hot-plugged MD300 modem 2013-10-17 15:25:52 -05:00
Szymon Janc 2d925003a4 gdbus: Remove not needed check for NULL DBusPendingCall
It is now checked by g_dbus_send_message_with_reply() so there is no
need to double check that in caller.
2013-10-14 06:06:31 -07:00
Szymon Janc df8cf542d8 gdbus: Check for NULL DBusPendingCall in g_dbus_send_message_with_reply
"Warning: if the connection is disconnected or you try to send Unix file
descriptors on a connection that does not support them, the
DBusPendingCall will be set to NULL, so be careful with this."

Check this in g_dbus_send_message_with_reply so that callers don't need
to double check for NULL if g_dbus_send_message_with_reply returned
TRUE.

This also fix crash if passing FD over D-Bus is blocked e.g. by SELinux
policy.

bluetoothd[1894]: profiles/audio/avdtp.c:session_cb()
bluetoothd[1894]: profiles/audio/avdtp.c:avdtp_parse_cmd() Received
    SET_CONFIGURATION_CMD
bluetoothd[1894]: profiles/audio/a2dp.c:endpoint_setconf_ind() Source
    0x6c5000: Set_Configuration_Ind
bluetoothd[1894]: profiles/audio/avdtp.c:avdtp_ref() 0x6df360: ref=1
bluetoothd[1894]: profiles/audio/a2dp.c:setup_ref() 0x6d32b0: ref=1
process 1894: arguments to dbus_pending_call_set_notify() were incorrect,
     assertion "pending != NULL" failed in file dbus-pending-call.c line
     636.
This is normally a bug in some application using the D-Bus library.
2013-10-14 06:06:31 -07:00
Denis Kenzior 2158249069 hfp_hf_bluez5: Be more pedantic in get_version
If no 'Version' key is found we might be assigning an uninitialized
value.  Return an error in this case as the 'Version' key is required.
2013-10-01 11:35:27 -05:00
Denis Kenzior c49ed15a8f hfp_hf_bluez5: Add version debug info 2013-10-01 11:28:19 -05:00
Vinicius Costa Gomes 51982e7b13 handsfree-audio: Don't listen() if no defer_setup
As we won't allow any card to be registered when the kernel doesn't
support defer_setup, we don't need to have the listening SCO socket
open in this case.
2013-09-12 13:17:40 -05:00
Vinicius Costa Gomes 6d08a47ec3 handsfree-audio: Don't register if no defer_setup
If the kernel doesn't support defer_setup for SCO, we shouldn't allow
cards to be registered, because in that case we won't be able to
properly send the file descriptor to the Agent.
2013-09-12 13:17:40 -05:00
Vinicius Costa Gomes e84bd27b99 handsfree-audio: Set socket parameters
In the AG case, the voice setting needs to be set before we can
use Transparent SCO mode, which is necessary for Wideband speech
support.
2013-09-12 13:17:40 -05:00
Vinicius Costa Gomes ff16aed8bd handsfree-audio: Detect transparent SCO in kernel
Deferred SCO setup is not enough for HFP 1.6 wideband codec support.
Wideband speech also requires Transparent SCO to be enabled in the
kernel.
2013-09-12 13:17:40 -05:00
Denis Kenzior e574d44d00 handsfree-audio: Tweak logic a bit 2013-09-12 13:17:40 -05:00
Vinicius Costa Gomes 0de0f496cb handsfree-audio: Add setting SCO air mode 2013-09-12 13:17:40 -05:00
Denis Kenzior 62c2b81db7 hfp_hf_bluez5: Remove Cancel method 2013-09-12 13:17:40 -05:00
Denis Kenzior f2103a7ada hfp_hf_bluez5: Mark Release method as NOREPLY 2013-09-12 13:17:39 -05:00
Denis Kenzior a8e4073d0e test: Add set-msisdn script 2013-09-12 13:17:39 -05:00
Denis Kenzior df25ccac49 test: Add display-icon script 2013-09-12 13:17:39 -05:00
Denis Kenzior a4a170e1ea hfpmodem: Call ofono_voicecall_mpty_hint as needed 2013-09-12 13:17:39 -05:00
Denis Kenzior 0026ae3fb7 atmodem: Update parse_clcc utility function 2013-09-12 13:17:39 -05:00
Denis Kenzior 394069cb59 voicecall: Implement ofono_voicecall_mpty_hint 2013-09-12 13:17:39 -05:00
Denis Kenzior 681bc6d556 include: Add voicecall multiparty hint method
On protocols that support creation of multiparty calls outside of
oFono's control, we need a way to detect multiparty call transitions.
This method adds a way for the driver to hint the core which calls
should be part of the multiparty call.

Right now this is relevant only to HFP.  Real modem hardware should not
be using this method.
2013-09-12 13:17:39 -05:00
Denis Kenzior d94eb705c7 test: Add selecting the modem in private-chat 2013-09-12 13:17:39 -05:00
Denis Kenzior 75e747122c test: Add selecting the modem in create-multiparty 2013-09-12 13:17:39 -05:00
Luiz Augusto von Dentz 2e5938f3bb gdbus/client: Use g_dbus_add_properties_watch to track properties
This make the handling much simpler and avoids duplicates of the same
match rule.
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz 607c1e088d gdbus/client: Use g_dbus_add_signal_watch to track signals
This make the handling much simpler and avoids duplicates of the same
match rule.
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz cb5f10d2c2 gdbus/client: Use g_dbus_add_service_watch to track services
This make the handling much simpler and avoids duplicates of the same
match rule.
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz b4b4b35d0b gdbus/watch: Fix crash when disconnecting from D-Bus
When disconnecting from D-Bus a message could be recieved with no sender:
Invalid read of size 1
   at 0x4A09EE1: strcmp (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
   by 0x3B03C386B8: g_str_equal (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x4065D6: message_filter (watch.c:529)
   by 0x3B0700F9E5: dbus_connection_dispatch (in /usr/lib64/libdbus-1.so.3.7.4)
   by 0x4052E7: message_dispatch (mainloop.c:76)
   by 0x3B03C48962: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x3B03C47E05: g_main_context_dispatch (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x3B03C48157: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x3B03C48559: g_main_loop_run (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x4038C5: client_proxy_removed (test-gdbus-client.c:902)
   by 0x3B03C6B566: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
   by 0x3B03C6B6E5: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
 Address 0x0 is not stack'd, malloc'd or (recently) free'd
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz 3849da14e5 gdbus/watch: Fix aborting when removing D-Bus filter
In case of filter_data having a watch to a service name it may call
dbus_connection_remove_filter twice causing libdbus to abort:

process 24723: Attempt to remove filter function 0x4063e0 user data (nil), but no such filter has been added

To fix this the code will now only attempt to call
dbus_connection_remove_filter once in filter_data_free which is the
counterpart of filter_data_get where dbus_connection_add_filter is called.
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz 68cc171e40 gdbus/watch: Fix crash when g_dbus_remove_watch is called from connect callback
at 0x40570C: update_service (watch.c:601)
 by 0x40584B: service_reply (watch.c:627)
 by 0x3B0700C511: ??? (in /usr/lib64/libdbus-1.so.3.7.4)
 by 0x3B0700F740: dbus_connection_dispatch (in /usr/lib64/libdbus-1.so.3.7.4)
 by 0x405167: message_dispatch (mainloop.c:76)
 by 0x3B03C48962: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
 by 0x3B03C47E05: g_main_context_dispatch (in /usr/lib64/libglib-2.0.so.0.3600.3)
 by 0x3B03C48157: ??? (in /usr/lib64/libglib-2.0.so.0.3600.3)
 by 0x3B03C48559: g_main_loop_run (in /usr/lib64/libglib-2.0.so.0.3600.3)
Address 0x4c58a30 is 32 bytes inside a block of size 56 free'd
 at 0x4A074C4: free (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
 by 0x3B03C4D9AE: g_free (in /usr/lib64/libglib-2.0.so.0.3600.3)
 by 0x406102: filter_data_remove_callback (watch.c:378)
 by 0x405FC0: g_dbus_remove_watch (watch.c:798)
 by 0x40A22B: g_dbus_client_unref (client.c:1227)
 by 0x40570B: update_service (watch.c:599)
 by 0x40584B: service_reply (watch.c:627)
2013-09-12 08:25:23 -07:00
Luiz Augusto von Dentz 778b60a94f gdbus: Fix emitting PropertiesChanged twice
This fixes double emission of PropertiesChanged introduced by flushing
changes, the flushing can happen during the pending processing so the
pending_prop flag needs to be updated in the beginning and the list of
properties can be freed before g_dbus_send_message as it is not required
anymore.
2013-09-10 19:07:28 -07:00
Luiz Augusto von Dentz 1ad938a5fd gdbus: Avoid calling dbus_connection_send*
dbus_connection_send* should not be called directly except by
g_dbus_send_message.
2013-09-10 19:07:28 -07:00
Luiz Augusto von Dentz 6a9a09a02a gdbus: Add g_dbus_send_message_with_reply
g_dbus_send_message_with_reply flushes pending signals before calling
dbus_connection_send_with_reply so it does not alter the message order
2013-09-10 19:07:28 -07:00
Luiz Augusto von Dentz f462a549f5 gdbus: Fix sending ObjectManager/Properties signals out of order
In some cases the order of the messages is altered when a message is
sent without processing the pending signals first, currently this affect
client_check_order unit test:

/gdbus/client_check_order: **
ERROR:unit/test-gdbus-client.c:795:property_check_order: assertion failed: (g_strcmp0(string, "value1") == 0)

As can be observed the value of the property is not yet updated because the
signal it is still pending, once this fix is applied the test pass:

/gdbus/client_check_order: OK

Note that the flushing only works when g_dbus_send_message is used so
places where dbus_connection_send and other variants are called directly
may still change the order.
2013-09-10 19:07:28 -07:00
Denis Kenzior d7ba153737 smsutil: Make sure to return 1/0
So the value might be used directly for D-Bus property emission.
Otherwise D-Bus asserts and screws itself with:
ofonod[7427]: src/sms.c:handle_mwi()
process 7427: arguments to dbus_message_iter_append_basic() were
incorrect, assertion "*bool_p == 0 || *bool_p == 1" failed in file
../../dbus/dbus-message.c line 2549.
2013-09-03 22:58:59 -05:00
Denis Kenzior 0cdf3ced1f test-sms: Add skeleton code for MWI unit test 2013-09-03 22:58:40 -05:00
Denis Kenzior c912e0066a hfp: Set UDUB affected set to WAITING only
INCOMING calls are not affected by UDUB, only by +CHUP.
2013-08-25 01:25:28 -05:00
Denis Kenzior fe36dec9a1 hfp: Fix up disconnect reason handling for +CHUP
The affected call types for +CHUP were set to only ACTIVE calls.
Instead the affected set should include INCOMING, DIALING, ALERTING and
ACTIVE calls.

Thanks to Ionut Dediu for the diagnosing and reporting this issue.
2013-08-25 01:21:23 -05:00
Vinicius Costa Gomes 8a11d38983 bluetooth: Add define for SCO voice settings
Add defines for SCO voice setting (Air Coding). Air mode "Transparent
Data" shall be supported if wide band speech is supported.
2013-08-19 12:14:39 -05:00