From: Luiz Augusto von Dentz <luiz.dentz@gmail.com>
To: linux-bluetooth@vger.kernel.org
Subject: [PATCH v4 3/3] android/avrcp: Fix setting wrong type for volume changed event
Date: Mon, 10 Mar 2014 14:05:16 +0200 [thread overview]
Message-ID: <1394453116-9354-3-git-send-email-luiz.dentz@gmail.com> (raw)
In-Reply-To: <1394453116-9354-1-git-send-email-luiz.dentz@gmail.com>
From: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
Notification for volume changed should carry the original ctype and
not translate to HAL_AVRCP_EVENT_TYPE_INTERIM or
HAL_AVRCP_EVENT_TYPE_CHANGED which are only valid for register
notification command.
---
android/avrcp.c | 12 +-----------
1 file changed, 1 insertion(+), 11 deletions(-)
diff --git a/android/avrcp.c b/android/avrcp.c
index eab519a..f0a6d59 100644
--- a/android/avrcp.c
+++ b/android/avrcp.c
@@ -788,17 +788,7 @@ static gboolean register_notification_rsp(struct avctp *conn,
if (params == NULL || params[0] != AVRCP_EVENT_VOLUME_CHANGED)
return FALSE;
- switch (code) {
- case AVC_CTYPE_INTERIM:
- ev.type = HAL_AVRCP_EVENT_TYPE_INTERIM;
- break;
- case AVC_CTYPE_CHANGED:
- ev.type = HAL_AVRCP_EVENT_TYPE_CHANGED;
- break;
- default:
- return FALSE;
- }
-
+ ev.type = code;
ev.volume = params[1] & 0x7F;
ipc_send_notif(hal_ipc, HAL_SERVICE_ID_AVRCP,
--
1.8.5.3
next prev parent reply other threads:[~2014-03-10 12:05 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-10 12:05 [PATCH v4 1/3] android/avrcp: Fill attributes in case of empty for GetElementAttributes Luiz Augusto von Dentz
2014-03-10 12:05 ` [PATCH v4 2/3] android/avrcp: Fix not handling SetAbsoluteVolume response Luiz Augusto von Dentz
2014-03-10 12:05 ` Luiz Augusto von Dentz [this message]
2014-03-10 12:12 ` [PATCH v4 1/3] android/avrcp: Fill attributes in case of empty for GetElementAttributes Luiz Augusto von Dentz
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=1394453116-9354-3-git-send-email-luiz.dentz@gmail.com \
--to=luiz.dentz@gmail.com \
--cc=linux-bluetooth@vger.kernel.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