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YVCwgQVZDX0NUWVBFX1NUQVRVUywNCk5VTEwgfSwNCnsgQVZSQ1BfRElTUExBWUFCTEVf
Q0hBUlNFVCwgQVZDX0NUWVBFX1NUQVRVUywNCi0tIA0KMS43LjUuNA0KDQpJbiB0aGUgYWJvdmUg
cGF0Y2ggdGhlIGZ1bmN0aW9uICJhdHRyX3RvX3N0ciIgaGF2ZSBiZWVuIHRha2VuIGZyb20gYXVk
aW8vbWVkaWEuYyBmaWxlLiANClNpbmNlIHRoZXJlIG1pZ3RoIGJlIGZldyBmdW5jdGlvbnMgdGhh
dCB3aWxsIGJlIHVzZWQgY29tbW9ubHkgaW4gYXVkaW8vYXZyY3AuYyBhbmQgYXVkaW8vbWVkaWEu
YyB3aHkgY2FuJ3QgDQpzdWNoIGZ1bnRpb25zIG1vdmVkIHRvIGEgY29tbW9uIGZpbGU/Lg0KDQpU
aGFua3MgYW5kIFJlZ2FyZHMNCkNoZXRoYW4NCi0tDQpUbyB1bnN1YnNjcmliZSBmcm9tIHRoaXMg
bGlzdDogc2VuZCB0aGUgbGluZSAidW5zdWJzY3JpYmUgbGludXgtYmx1ZXRvb3RoIiBpbg0KdGhl
IGJvZHkgb2YgYSBtZXNzYWdlIHRvIG1ham9yZG9tb0B2Z2VyLmtlcm5lbC5vcmcNCk1vcmUgbWFq
b3Jkb21vIGluZm8gYXQgIGh0dHA6Ly92Z2VyLmtlcm5lbC5vcmcvbWFqb3Jkb21vLWluZm8uaHRt
bA==
Hi,
--------------------------------------------------
From: "Luiz Augusto von Dentz" <[email protected]>
Sent: Wednesday, March 21, 2012 10:53 PM
To: <[email protected]>
Cc: <[email protected]>
Subject: Re: [PATCH] avrcp: Handle of
GetPlayerApplicationSettingAttributeText pdu
> Hi,
>
> On Wed, Mar 21, 2012 at 2:56 AM, CHETHAN TN <[email protected]>
> wrote:
>>
>> In the above patch the function "attr_to_str" have been taken from
>> audio/media.c file.
>> Since there migth be few functions that will be used commonly in
>> audio/avrcp.c and audio/media.c why can't
>> such funtions moved to a common file?.
>
> Actually we might want to handle this in media.c, so perhaps we can
> reuse the callback to gets an attribute or create a new one to fetch
> the text in case of this being dynamically, otherwise just have it
> inline in avrcp.h might be fine.
>
>
> --
> Luiz Augusto von Dentz
Thanks for you valuable information.
I agree on your suggestions and implement it as inline functions in avrcp.h.
Regards
Chethan
Hi,
On Wed, Mar 21, 2012 at 2:56 AM, CHETHAN TN <[email protected]> wrote:
>
> In the above patch the function "attr_to_str" have been taken from audio/media.c file.
> Since there migth be few functions that will be used commonly in audio/avrcp.c and audio/media.c why can't
> such funtions moved to a common file?.
Actually we might want to handle this in media.c, so perhaps we can
reuse the callback to gets an attribute or create a new one to fetch
the text in case of this being dynamically, otherwise just have it
inline in avrcp.h might be fine.
--
Luiz Augusto von Dentz