Re: [PATCH 1/3] AVRCP: Add missing capability for TrackReachedEnd

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Michal,

On Wed, Apr 11, 2012 at 12:12 PM, Michal Labedzki
<michal.labedzki@xxxxxxxxx> wrote:
> Add missing capability for TrackReachedEnd.
> ---
>  audio/avrcp.c |    5 +++--
>  1 files changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/audio/avrcp.c b/audio/avrcp.c
> index 8eba046..d456023 100644
> --- a/audio/avrcp.c
> +++ b/audio/avrcp.c
> @@ -557,11 +557,12 @@ static uint8_t avrcp_handle_get_capabilities(struct avrcp_player *player,
>
>                return AVC_CTYPE_STABLE;
>        case CAP_EVENTS_SUPPORTED:
> -               pdu->params_len = htons(5);
> -               pdu->params[1] = 3;
> +               pdu->params_len = htons(2 + 4);

I think we could have params_lens done latter using params[1] e.g
pdu->params_len = htons(2 + pdu->params[1]) to make it simpler to add
new events.

> +               pdu->params[1] = 4;
>                pdu->params[2] = AVRCP_EVENT_STATUS_CHANGED;
>                pdu->params[3] = AVRCP_EVENT_TRACK_CHANGED;
>                pdu->params[4] = AVRCP_EVENT_TRACK_REACHED_START;
> +               pdu->params[5] = AVRCP_EVENT_TRACK_REACHED_END;
>
>                return AVC_CTYPE_STABLE;
>        }
> --
> on behalf of ST-Ericsson

The rest looks good.

-- 
Luiz Augusto von Dentz
--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux