From: Frederic Danis <frederic.danis@linux.intel.com>
To: ofono@ofono.org
Subject: Re: [PATCH v0 13/15] handsfree-audio: Return InProgress on Connect
Date: Tue, 12 Mar 2013 16:26:54 +0100 [thread overview]
Message-ID: <513F493E.9090104@linux.intel.com> (raw)
In-Reply-To: <1363092133-1092-14-git-send-email-claudio.takahasi@openbossa.org>
[-- Attachment #1: Type: text/plain, Size: 1117 bytes --]
Hello Claudio,
On 12/03/2013 13:42, Claudio Takahasi wrote:
> This patch returns "Operation already in progress" if there is a
> pending Handsfree Audio Card "Connect" method call pending.
> ---
> src/handsfree-audio.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/src/handsfree-audio.c b/src/handsfree-audio.c
> index 8950347..805f3b6 100644
> --- a/src/handsfree-audio.c
> +++ b/src/handsfree-audio.c
> @@ -285,6 +285,9 @@ static DBusMessage *card_connect(DBusConnection *conn,
> if (agent == NULL)
> return __ofono_error_not_available(msg);
>
> + if (card->msg)
> + return __ofono_error_busy(msg);
> +
> sk = driver->audio_connect(card->remote, card->local);
> if (sk < 0)
> return __ofono_error_failed(msg);
>
Shouldn't you also test if there is already a SCO connection (sco_watch) ?
I think that only one SCO link can be connected at a time for a
Handsfree Audio Card.
Regards
Fred
--
Frederic Danis Open Source Technology Center
frederic.danis(a)intel.com Intel Corporation
next prev parent reply other threads:[~2013-03-12 15:26 UTC|newest]
Thread overview: 43+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-08 23:11 [RFC v0 00/13] Add handsfree audio card driver Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 01/13] handsfree-audio: Add " Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 02/13] hfp_hf_bluez5: Register handsfree audio driver Claudio Takahasi
2013-03-11 14:30 ` Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 03/13] hfp_hf_bluez5: Add extracting version Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 04/13] handsfree-audio: Add version to card driver Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 05/13] hfp_hf_bluez5: Pass version to card registration Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 06/13] hfp_hf_bluez5: Add version to HFP 1.5 card driver Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 07/13] core: Add bt_str2ba() to bluetooth.h Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 08/13] hfp_hf_bluez5: Add HFP 1.5 card connect callback Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 09/13] handsfree-audio: Add calling " Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 10/13] handsfree-audio: Add connect GIOChannel watch Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 11/13] handsfree-audio: Add sending SCO fd Claudio Takahasi
2013-03-11 14:55 ` Johan Hedberg
2013-03-11 16:36 ` Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 12/13] handsfree-audio: Return an error on Card Connect Claudio Takahasi
2013-03-08 23:11 ` [RFC v0 13/13] handsfree-audio: Check agent before sending fd Claudio Takahasi
2013-03-12 12:41 ` [PATCH v0 00/15] Add handsfree audio card driver Claudio Takahasi
2013-03-12 12:41 ` [PATCH v0 01/15] handsfree-audio: Add " Claudio Takahasi
2013-03-13 16:53 ` Frederic Danis
2013-03-13 17:46 ` Denis Kenzior
2013-03-14 9:59 ` Frederic Danis
2013-03-18 18:58 ` Denis Kenzior
2013-03-12 12:42 ` [PATCH v0 02/15] hfp_hf_bluez5: Register handsfree audio driver Claudio Takahasi
2013-03-18 18:59 ` Denis Kenzior
2013-03-12 12:42 ` [PATCH v0 03/15] hfp_hf_bluez5: Add extracting version Claudio Takahasi
2013-03-18 18:55 ` Denis Kenzior
2013-03-12 12:42 ` [PATCH v0 04/15] handsfree-audio: Add version to card driver Claudio Takahasi
2013-03-18 18:59 ` Denis Kenzior
2013-03-12 12:42 ` [PATCH v0 05/15] hfp_hf_bluez5: Pass version to card registration Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 06/15] hfp_hf_bluez5: Add version to HFP 1.5 card driver Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 07/15] core: Add bt_str2ba() to bluetooth.h Claudio Takahasi
2013-03-18 19:00 ` Denis Kenzior
2013-03-12 12:42 ` [PATCH v0 08/15] hfp_hf_bluez5: Add HFP 1.5 connect implementation Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 09/15] handsfree-audio: Add calling connect callback Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 10/15] handsfree-audio: Add connect GIOChannel watch Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 11/15] handsfree-audio: Add sending SCO fd Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 12/15] handsfree-audio: Return NotAvailable on "Connect" Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 13/15] handsfree-audio: Return InProgress on Connect Claudio Takahasi
2013-03-12 15:26 ` Frederic Danis [this message]
2013-03-12 17:26 ` Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 14/15] handsfree-audio: Check agent before sending fd Claudio Takahasi
2013-03-12 12:42 ` [PATCH v0 15/15] doc: Add Handsfree Audio Card "Connect" errors Claudio Takahasi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=513F493E.9090104@linux.intel.com \
--to=frederic.danis@linux.intel.com \
--cc=ofono@ofono.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox