android/hal-ipc-api: Use variable length for text attributes

This prevent having to increase the MTU size just to fit all attributes
when in fact some attributes are numbers (3 out of 8) in text format
which should not get even close to use 256 bytes defined by bt_rc.h.
This commit is contained in:
Luiz Augusto von Dentz 2014-02-19 18:58:46 +02:00 committed by Szymon Janc
parent 1446bca69d
commit ff33778a87
2 changed files with 6 additions and 3 deletions

View File

@ -1257,7 +1257,8 @@ Android HAL name: "avrcp" (BT_PROFILE_AV_RC_ID)
Command parameters: Number of values (1 octet)
Value # (1 octet)
Value # text (255 octets)
Value # text length (1 octet)
Value # text (variable)
...
In case of an error, the error response will be returned.
@ -1266,7 +1267,8 @@ Android HAL name: "avrcp" (BT_PROFILE_AV_RC_ID)
Command parameters: Number of elements (1 octet)
Element # (1 octet)
Element # text (255 octets)
Element # text length (1 octet)
Element # text (variable)
...
In case of an error, the error response will be returned.

View File

@ -837,7 +837,8 @@ struct hal_cmd_avrcp_get_player_attrs {
struct hal_avrcp_player_setting_text {
uint8_t id;
uint8_t text[255];
uint8_t len;
uint8_t text[0];
} __attribute__((packed));
#define HAL_OP_AVRCP_GET_PLAYER_ATTRS_TEXT 0x05