From: Denis Kenzior <denkenz@gmail.com>
To: ofono@ofono.org
Subject: Re: [PATCH 1/2] hfpmodem: fix hf features
Date: Fri, 05 Aug 2011 17:09:46 -0500 [thread overview]
Message-ID: <4E3C6A2A.9060002@gmail.com> (raw)
In-Reply-To: <1312462544-21581-2-git-send-email-frederic.danis@linux.intel.com>
[-- Attachment #1: Type: text/plain, Size: 1504 bytes --]
Hi Frédéric,
On 08/04/2011 07:55 AM, Frédéric Danis wrote:
> check audio gateway version and only set right features
> ---
> drivers/hfpmodem/slc.c | 5 +++++
> drivers/hfpmodem/slc.h | 1 +
> 2 files changed, 6 insertions(+), 0 deletions(-)
>
> diff --git a/drivers/hfpmodem/slc.c b/drivers/hfpmodem/slc.c
> index f9eca22..db1c3b9 100644
> --- a/drivers/hfpmodem/slc.c
> +++ b/drivers/hfpmodem/slc.c
> @@ -60,9 +60,14 @@ void hfp_slc_info_init(struct hfp_slc_info *info)
> info->hf_features = HFP_HF_FEATURE_3WAY;
> info->hf_features |= HFP_HF_FEATURE_CLIP;
> info->hf_features |= HFP_HF_FEATURE_REMOTE_VOLUME_CONTROL;
> +
> + if (info->ag_version < 0x0105)
> + goto done;
> +
> info->hf_features |= HFP_HF_FEATURE_ENHANCED_CALL_STATUS;
> info->hf_features |= HFP_HF_FEATURE_ENHANCED_CALL_CONTROL;
>
> +done:
> memset(info->cind_val, 0, sizeof(info->cind_val));
> memset(info->cind_pos, 0, sizeof(info->cind_pos));
> }
> diff --git a/drivers/hfpmodem/slc.h b/drivers/hfpmodem/slc.h
> index f37a59c..7f4203f 100644
> --- a/drivers/hfpmodem/slc.h
> +++ b/drivers/hfpmodem/slc.h
> @@ -42,6 +42,7 @@ typedef void (*hfp_slc_cb_t)(void *userdata);
>
> struct hfp_slc_info {
> GAtChat *chat;
> + int ag_version;
I think you can avoid introducing this member if you simply pass the
version into hfp_slc_info_init.
> unsigned int ag_features;
> unsigned int ag_mpty_features;
> unsigned int hf_features;
Regards,
-Denis
next prev parent reply other threads:[~2011-08-05 22:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-04 12:55 [PATCH 0/2] add profile version to HandsfreeAgent =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Danis
2011-08-04 12:55 ` [PATCH 1/2] hfpmodem: fix hf features =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Danis
2011-08-05 22:09 ` Denis Kenzior [this message]
2011-08-04 12:55 ` [PATCH 2/2] hfp_hf: retrieve AG version =?unknown-8bit?q?Fr=C3=A9d=C3=A9ric?= Danis
2011-08-05 22:13 ` Denis Kenzior
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=4E3C6A2A.9060002@gmail.com \
--to=denkenz@gmail.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