summaryrefslogtreecommitdiffstats
path: root/audio/avdtp.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove temporary watch if the connection was accepted.Luiz Augusto von Dentz2009-03-051-0/+3
|
* Set avdtp session watch to low priority.Luiz Augusto von Dentz2009-03-051-2/+12
| | | | | | | | | The session watch should be low priority because on old kernels (prior to DEFER_SETUP). This is needed for stream Open & Start because the connection is automatically accepted and makes the remote device to sending the Start command imediately. Since both the stream transport connection and the Start command arrive so close to each other the kernel might wake up bluetoothd at the same time for both.
* Cleanup pending request queue after before freeing streamJohan Hedberg2009-02-261-0/+33
| | | | | Any requests related to the stream should be removed from the queue when the stream state goes to IDLE and the stream gets free'd.
* Fix stream rejection size checkJohan Hedberg2009-02-261-1/+1
|
* Fix memory leakJohan Hedberg2009-02-241-1/+5
|
* Fix stream channel closingJohan Hedberg2009-02-241-4/+3
|
* Don't call g_io_channel_shutdown if the session was removedJohan Hedberg2009-02-241-1/+0
| | | | | In this rather unusual scenario g_io_channel_shutdown will already have been called so attempting it again would cause a GLib warning.
* Close the correct GIOCHannel in avdtp_close_respJohan Hedberg2009-02-231-1/+1
| | | | avdtp_close_resp should close the stream and not the signaling channel
* Fix connection authorization when the device is trustedJohan Hedberg2009-02-191-4/+3
|
* Fix finalize_discovery calls to pass correct error codeJohan Hedberg2009-02-191-2/+2
|
* Unify connection_lost() calling conventionsJohan Hedberg2009-02-191-6/+6
|
* Make use of g_io_channel_shutdown instead of deprecated g_io_channel_close.Luiz Augusto von Dentz2009-02-191-3/+3
|
* Make use of g_error_free instead of g_clear_error when possible.Luiz Augusto von Dentz2009-02-191-1/+1
| | | | | g_clear_error make an extra operation (&err = NULL) which is not necessary when the GError is not reused.
* Don't dereference the session if it was closedJohan Hedberg2009-02-191-1/+3
|
* No need to pass connect_cb if confirm_cb is passedJohan Hedberg2009-02-191-1/+1
|
* Convert AVDTP code to use btio confirm_cbJohan Hedberg2009-02-191-224/+210
|
* Make audio plugin to use BtIO API.Luiz Augusto von Dentz2009-02-191-62/+74
|
* Fix authorization cancelation when connection dropsJohan Hedberg2009-02-061-7/+8
|
* Delay AVRCP connection when remote device connects A2DPJohan Hedberg2009-02-041-3/+5
| | | | | | | The audio profile coexistence whitepaper recommends that the initiator of the A2DP connection also initiates the AVRCP connection. This patch adds a two second delay before we attempt connecting AVRCP after the remote device has connected A2DP to us.
* Set up a stream for incoming connections if the sink doesn't do itJohan Hedberg2009-02-021-1/+15
| | | | | | | | | | | | | | Some headsets when acting as initiators of an AVDTP connection create the AVDTP signaling channel but don't do anything else over it (i.e. they expect us to set up a stream when needed). This patch makes bluetoothd do the same as AudioSink.Connect() if no AVDTP commands have been received from the sink within one second after it has created the AVDTP signaling channel to us. Setting up a stream is also important because the AudioSink Connected property is bound to the existence of a configured stream (which makes sense since an AVDTP connection as such tells us nothing about what sinks and sources there are or even if audio or video will be used).
* Decrease AVDTP idle timeout to 1 secondJohan Hedberg2009-02-021-1/+1
|
* Fix signed/unsigned comparison issues within AVDTP/A2DP codeMarcel Holtmann2009-01-301-15/+15
|
* Implement AVDTP signal fragmentation supportJohan Hedberg2009-01-281-293/+487
| | | | | | This patch implements AVDTP signal fragmentation. Even though it's a mandatory feature it in practice it never gets used with A2DP as it requires messages that exceed 48 bytes (the minimum L2CAP MTU).
* Don't auto-disconnect explicitly created A2DP connectionsJohan Hedberg2009-01-271-1/+14
| | | | | | | | | This patch makes sure that explicitly created connections (remotely initiated or using AudioSink.Connect()) stay up until explictly disconnected. The control for this needs to be in the stream timer and not the disconnect timer since our AVDTP state machine always tries to keep one stream in configured state (i.e. it should be ok to always disconnect if we stay too long in IDLE state).
* Update copyright informationMarcel Holtmann2009-01-011-1/+1
|
* Add another missing check for btd_device_add_uuid.Luiz Augusto von Dentz2008-12-021-1/+6
|
* Make use of g_timeout_add_seconds whenever possible.Luiz Augusto von Dentz2008-11-171-9/+13
|
* Set stream timer in avdtp_sep_set_state instead of avdtp_suspend_respJohan Hedberg2008-10-251-4/+6
| | | | | This ensures that the timer is not only set when we requested the suspend but also when the other side requested the suspend.
* Perform a proper abort upon stream connect failureJohan Hedberg2008-10-201-4/+8
|
* Check for existing STREAMING state when receiving START_RSPJohan Hedberg2008-10-191-1/+4
| | | | | | | This could happen if both peers send START_CMD at the same time and the SNK peer doesn't reject the command (as it should according to the spec). This behaviour can be seen e.g. when using pulseaudio and the Mororola S9 headset.
* Remove OPEN state change from avdtp_open_cmdJohan Hedberg2008-10-191-1/+0
| | | | | | | | | | | | Some time back the INT role OPEN transition was moved from receiving the OPEN response to actually having the stream L2CAP channel ready. Unfortunatly this patch forgot to change the ACP case so the code has so far attempted a double ->OPEN transition. According to the AVDTP spec the transition should happen before the stream L2CAP transport but this doesn't really make sense since several places want to have the stream fd ready when we go to the OPEN state. Therefore, this patch removes the ACP role OPEN transition from receiving the OPEN command and lets the state change be in having the stream L2CAP transport established.
* Add mechanism for adding new UUIDs from the driver sideJohan Hedberg2008-10-091-4/+6
| | | | | | With this patch drivers can notify the core daemon that a device supports some UUID. This is useful in case we don't have a service record for a profile which the remote device initiates a connection for.
* Check for NULL streamJohan Hedberg2008-10-091-0/+3
|
* Move dev->sink initialization as acceptor to correct placeJohan Hedberg2008-10-081-3/+19
| | | | | | | We can't initialize dev->sink in the AVDTP server callback since at this point we don't know if the remote device will be acting in audio source or audio sink role. So, do the initialization when we get the SetConfiguration command since then we can check the type of the SEP that was selected.
* Create audio device objects on incoming connections if necessaryJohan Hedberg2008-10-081-0/+11
| | | | | | If we haven't done SDP yet the data structures will be uninitialized. This patch makes sure that the structures are properly initialized if we get an incoming connection before service discovery has been done.
* Don't do double g_io_channel_unref if btd_request_authorization failsJohan Hedberg2008-10-081-2/+2
|
* Fix coding styleMarcel Holtmann2008-10-061-2/+1
|
* Cancel any pending authorization request if the connection gets dropedJohan Hedberg2008-10-061-0/+2
|
* Fix AVDTP_STATE_OPEN to happen only after connected and thus prevent ↵Luiz Augusto von Dentz2008-10-011-2/+2
| | | | emitting Connected signal when not connected.
* Prevent passing stdin (0) as a audio transport to applications.Luiz Augusto von Dentz2008-10-011-1/+1
|
* Fix another potential invalid read.Luiz Augusto von Dentz2008-10-011-1/+1
|
* Cancels the pending request from agent side when receiving a NoReplyVinicius Costa Gomes2008-09-091-5/+0
|
* Fix a2dp and avrcp drivers to not rely on BDADDR_ANY.Luiz Augusto von Dentz2008-09-081-43/+90
|
* Don't use L2CAP_LM_SECURE and RFCOMM_LM_SECURE for nowMarcel Holtmann2008-08-191-3/+1
|
* Remove driver.c driver.h and remove workaround for to force a symbol resolution.Luiz Augusto von Dentz2008-08-181-4/+5
|
* Fix authorization mechanism for 3.x.Luiz Augusto von Dentz2008-06-171-32/+2
|
* Replace struct device with struct audio_deviceMarcel Holtmann2008-05-291-3/+3
|
* Make control.c to use bt_l2cap_listen.Luiz Augusto von Dentz2008-05-271-1/+1
|
* Fix problem with non const bdaddr_tMarcel Holtmann2008-05-151-2/+2
|
* Remove casts.Luiz Augusto von Dentz2008-05-151-5/+5
|