sound: usb: Update USB audio QMI data structure

Updating USB audio qmi data structure as per new
definitions. Also update the USB audio QMI driver
appropriately.

Change-Id: I93ed98a17daa1c65944dd260c7004f7198741aad
Signed-off-by: Hemant Kumar <hemantk@codeaurora.org>
diff --git a/sound/usb/usb_audio_qmi_svc.c b/sound/usb/usb_audio_qmi_svc.c
index 300b602..b3b9774 100644
--- a/sound/usb/usb_audio_qmi_svc.c
+++ b/sound/usb/usb_audio_qmi_svc.c
@@ -404,12 +404,15 @@
 				subs->interface, subs->altset_idx);
 			goto err;
 		}
-		resp->bDelay = as->bDelay;
+		resp->data_path_delay = as->bDelay;
+		resp->data_path_delay_valid = 1;
 		fmt_v1 = (struct uac_format_type_i_discrete_descriptor *)fmt;
-		resp->bSubslotSize = fmt_v1->bSubframeSize;
+		resp->usb_audio_subslot_size = fmt_v1->bSubframeSize;
+		resp->usb_audio_subslot_size_valid = 1;
 	} else if (protocol == UAC_VERSION_2) {
 		fmt_v2 = (struct uac_format_type_i_ext_descriptor *)fmt;
-		resp->bSubslotSize = fmt_v2->bSubslotSize;
+		resp->usb_audio_subslot_size = fmt_v2->bSubslotSize;
+		resp->usb_audio_subslot_size_valid = 1;
 	} else {
 		pr_err("%s: unknown protocol version %x\n", __func__, protocol);
 		goto err;
@@ -423,11 +426,14 @@
 			subs->interface, subs->altset_idx);
 		goto err;
 	}
-	resp->bcdADC = ac->bcdADC;
+	resp->usb_audio_spec_revision = ac->bcdADC;
+	resp->usb_audio_spec_revision_valid = 1;
 
 	resp->slot_id = subs->dev->slot_id;
+	resp->slot_id_valid = 1;
 
 	memcpy(&resp->std_as_opr_intf_desc, &alts->desc, sizeof(alts->desc));
+	resp->std_as_opr_intf_desc_valid = 1;
 
 	ep = usb_pipe_endpoint(subs->dev, subs->data_endpoint->pipe);
 	if (!ep) {
@@ -436,6 +442,7 @@
 		goto err;
 	}
 	memcpy(&resp->std_as_data_ep_desc, &ep->desc, sizeof(ep->desc));
+	resp->std_as_data_ep_desc_valid = 1;
 
 	xhci_pa = usb_get_xfer_ring_dma_addr(subs->dev, ep);
 	if (!xhci_pa) {
@@ -453,6 +460,8 @@
 			goto err;
 		}
 		memcpy(&resp->std_as_sync_ep_desc, &ep->desc, sizeof(ep->desc));
+		resp->std_as_sync_ep_desc_valid = 1;
+
 		xhci_pa = usb_get_xfer_ring_dma_addr(subs->dev, ep);
 		if (!xhci_pa) {
 			pr_err("%s:failed to get sync ep ring dma address\n",
@@ -463,6 +472,7 @@
 	}
 
 	resp->interrupter_num = uaudio_qdev->intr_num;
+	resp->interrupter_num_valid = 1;
 
 	/*  map xhci data structures PA memory to iova */
 
@@ -569,6 +579,8 @@
 	resp->xhci_mem_info.xfer_buff.va = PREPEND_SID_TO_IOVA(va,
 						uaudio_qdev->sid);
 
+	resp->xhci_mem_info_valid = 1;
+
 	if (!atomic_read(&uadev[card_num].in_use)) {
 		kref_init(&uadev[card_num].kref);
 		init_waitqueue_head(&uadev[card_num].disconnect_wq);
@@ -733,7 +745,7 @@
 static int handle_uaudio_stream_req(void *req_h, void *req)
 {
 	struct qmi_uaudio_stream_req_msg_v01 *req_msg;
-	struct qmi_uaudio_stream_resp_msg_v01 resp = {0};
+	struct qmi_uaudio_stream_resp_msg_v01 resp = {{0}, 0};
 	struct snd_usb_substream *subs;
 	struct snd_usb_audio *chip = NULL;
 	struct uaudio_qmi_svc *svc = uaudio_svc;
@@ -743,6 +755,13 @@
 
 	req_msg = (struct qmi_uaudio_stream_req_msg_v01 *)req;
 
+	if (!req_msg->audio_format_valid || !req_msg->bit_rate_valid ||
+	!req_msg->number_of_ch_valid || !req_msg->xfer_buff_size_valid) {
+		pr_err("%s: invalid request msg\n", __func__);
+		ret = -EINVAL;
+		goto response;
+	}
+
 	direction = req_msg->usb_token & SND_PCM_STREAM_DIRECTION;
 	pcm_dev_num = (req_msg->usb_token & SND_PCM_DEV_NUM_MASK) >> 8;
 	pcm_card_num = (req_msg->usb_token & SND_PCM_CARD_NUM_MASK) >> 16;
@@ -827,7 +846,12 @@
 					uaudio_dev_release);
 	}
 
-	resp.status = ret;
+	resp.usb_token = req_msg->usb_token;
+	resp.usb_token_valid = 1;
+	resp.internal_status = ret;
+	resp.internal_status_valid = 1;
+	resp.status = ret ? USB_AUDIO_STREAM_REQ_FAILURE_V01 : ret;
+	resp.status_valid = 1;
 	ret = qmi_send_resp_from_cb(svc->uaudio_svc_hdl, svc->curr_conn, req_h,
 			&uaudio_stream_resp_desc, &resp, sizeof(resp));
 
diff --git a/sound/usb/usb_audio_qmi_v01.c b/sound/usb/usb_audio_qmi_v01.c
index a43d1dc..fef7505 100644
--- a/sound/usb/usb_audio_qmi_v01.c
+++ b/sound/usb/usb_audio_qmi_v01.c
@@ -280,20 +280,11 @@
 
 struct elem_info qmi_uaudio_stream_req_msg_v01_ei[] = {
 	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
-		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
-		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x01,
-		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
-					   priv_data),
-	},
-	{
 		.data_type      = QMI_UNSIGNED_1_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x02,
+		.tlv_type       = 0x01,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
 					   enable),
 	},
@@ -302,43 +293,79 @@
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint32_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x03,
+		.tlv_type       = 0x02,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
 					   usb_token),
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x10,
+		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
+					   audio_format_valid),
+	},
+	{
 		.data_type      = QMI_UNSIGNED_4_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint32_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x04,
+		.tlv_type       = 0x10,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
 					   audio_format),
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x11,
+		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
+					   number_of_ch_valid),
+	},
+	{
 		.data_type      = QMI_UNSIGNED_4_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint32_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x05,
+		.tlv_type       = 0x11,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
 					   number_of_ch),
 	},
 	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
+		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x06,
+		.tlv_type       = 0x12,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
-					   bit_rate),
+					   bit_rate_valid),
 	},
 	{
 		.data_type      = QMI_UNSIGNED_4_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint32_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x07,
+		.tlv_type       = 0x12,
+		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
+					   bit_rate),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x13,
+		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
+					   xfer_buff_size_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint32_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x13,
 		.offset         = offsetof(struct qmi_uaudio_stream_req_msg_v01,
 					   xfer_buff_size),
 	},
@@ -351,115 +378,256 @@
 
 struct elem_info qmi_uaudio_stream_resp_msg_v01_ei[] = {
 	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
-		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x01,
-		.offset         = offsetof(
-					struct qmi_uaudio_stream_resp_msg_v01,
-					priv_data),
-	},
-	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
-		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
+		.elem_size      = sizeof(struct qmi_response_type_v01),
 		.is_array       = NO_ARRAY,
 		.tlv_type       = 0x02,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
+					resp),
+		.ei_array      = get_qmi_response_type_v01_ei(),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x10,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					status_valid),
+	},
+	{
+		.data_type      = QMI_SIGNED_4_BYTE_ENUM,
+		.elem_len       = 1,
+		.elem_size      = sizeof(enum usb_audio_stream_status_enum_v01),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x10,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
 					status),
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x11,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					internal_status_valid),
+	},
+	{
 		.data_type      = QMI_UNSIGNED_4_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint32_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x03,
+		.tlv_type       = 0x11,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					internal_status),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x12,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					slot_id_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint32_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x12,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
 					slot_id),
 	},
 	{
-		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x04,
+		.tlv_type       = 0x13,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
-					bSubslotSize),
+					usb_token_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint32_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x13,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					usb_token),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x14,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					std_as_opr_intf_desc_valid),
 	},
 	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct usb_interface_descriptor_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x05,
+		.tlv_type       = 0x14,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
 					std_as_opr_intf_desc),
 		.ei_array      = usb_interface_descriptor_v01_ei,
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x15,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					std_as_data_ep_desc_valid),
+	},
+	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct usb_endpoint_descriptor_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x06,
+		.tlv_type       = 0x15,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
 					std_as_data_ep_desc),
 		.ei_array      = usb_endpoint_descriptor_v01_ei,
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x16,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					std_as_sync_ep_desc_valid),
+	},
+	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct usb_endpoint_descriptor_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x07,
+		.tlv_type       = 0x16,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
 					std_as_sync_ep_desc),
 		.ei_array      = usb_endpoint_descriptor_v01_ei,
 	},
 	{
-		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x08,
+		.tlv_type       = 0x17,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
-					bDelay),
+					usb_audio_spec_revision_valid),
 	},
 	{
 		.data_type      = QMI_UNSIGNED_2_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint16_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x09,
+		.tlv_type       = 0x17,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
-					bcdADC),
+					usb_audio_spec_revision),
 	},
 	{
-		.data_type      = QMI_STRUCT,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
-		.elem_size      = sizeof(struct apps_mem_info_v01),
+		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x0A,
+		.tlv_type       = 0x18,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
-					xhci_mem_info),
-		.ei_array      = apps_mem_info_v01_ei,
+					data_path_delay_valid),
 	},
 	{
 		.data_type      = QMI_UNSIGNED_1_BYTE,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x0B,
+		.tlv_type       = 0x18,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					data_path_delay),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x19,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					usb_audio_subslot_size_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x19,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					usb_audio_subslot_size),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x1A,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					xhci_mem_info_valid),
+	},
+	{
+		.data_type      = QMI_STRUCT,
+		.elem_len       = 1,
+		.elem_size      = sizeof(struct apps_mem_info_v01),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x1A,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					xhci_mem_info),
+		.ei_array      = apps_mem_info_v01_ei,
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x1B,
+		.offset         = offsetof(
+					struct qmi_uaudio_stream_resp_msg_v01,
+					interrupter_num_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x1B,
 		.offset         = offsetof(
 					struct qmi_uaudio_stream_resp_msg_v01,
 					interrupter_num),
@@ -473,13 +641,14 @@
 
 struct elem_info qmi_uaudio_stream_ind_msg_v01_ei[] = {
 	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.data_type      = QMI_SIGNED_4_BYTE_ENUM,
 		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
+		.elem_size      = sizeof(
+				enum usb_audio_device_indication_enum_v01),
 		.is_array       = NO_ARRAY,
 		.tlv_type       = 0x01,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
-					   usb_token),
+					   dev_event),
 	},
 	{
 		.data_type      = QMI_UNSIGNED_4_BYTE,
@@ -488,76 +657,175 @@
 		.is_array       = NO_ARRAY,
 		.tlv_type       = 0x02,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
-					   priv_data),
-	},
-	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
-		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
-		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x03,
-		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
-					   status),
-	},
-	{
-		.data_type      = QMI_UNSIGNED_4_BYTE,
-		.elem_len       = 1,
-		.elem_size      = sizeof(uint32_t),
-		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x04,
-		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
 					   slot_id),
 	},
 	{
-		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
 		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x05,
+		.tlv_type       = 0x10,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
-					   bSubslotSize),
+					   usb_token_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_4_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint32_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x10,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   usb_token),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x11,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   std_as_opr_intf_desc_valid),
 	},
 	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct usb_interface_descriptor_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x06,
+		.tlv_type       = 0x11,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
 					   std_as_opr_intf_desc),
 		.ei_array      = usb_interface_descriptor_v01_ei,
 	},
 	{
-		.data_type      = QMI_STRUCT,
+		.data_type      = QMI_OPT_FLAG,
 		.elem_len       = 1,
-		.elem_size      = sizeof(struct usb_endpoint_descriptor_v01),
+		.elem_size      = sizeof(uint8_t),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x07,
+		.tlv_type       = 0x12,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
-					   std_as_data_ep_desc),
-		.ei_array      = usb_endpoint_descriptor_v01_ei,
+					   std_as_data_ep_desc_valid),
 	},
 	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct usb_endpoint_descriptor_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x08,
+		.tlv_type       = 0x12,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   std_as_data_ep_desc),
+		.ei_array      = usb_endpoint_descriptor_v01_ei,
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x13,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   std_as_sync_ep_desc_valid),
+	},
+	{
+		.data_type      = QMI_STRUCT,
+		.elem_len       = 1,
+		.elem_size      = sizeof(struct usb_endpoint_descriptor_v01),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x13,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
 					   std_as_sync_ep_desc),
 		.ei_array      = usb_endpoint_descriptor_v01_ei,
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x14,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   usb_audio_spec_revision_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_2_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint16_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x14,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   usb_audio_spec_revision),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x15,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   data_path_delay_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x15,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   data_path_delay),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x16,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   usb_audio_subslot_size_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x16,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   usb_audio_subslot_size),
+	},
+	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x17,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   xhci_mem_info_valid),
+	},
+	{
 		.data_type      = QMI_STRUCT,
 		.elem_len       = 1,
 		.elem_size      = sizeof(struct apps_mem_info_v01),
 		.is_array       = NO_ARRAY,
-		.tlv_type       = 0x09,
+		.tlv_type       = 0x17,
 		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
 					   xhci_mem_info),
 		.ei_array      = apps_mem_info_v01_ei,
 	},
 	{
+		.data_type      = QMI_OPT_FLAG,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x18,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   interrupter_num_valid),
+	},
+	{
+		.data_type      = QMI_UNSIGNED_1_BYTE,
+		.elem_len       = 1,
+		.elem_size      = sizeof(uint8_t),
+		.is_array       = NO_ARRAY,
+		.tlv_type       = 0x18,
+		.offset         = offsetof(struct qmi_uaudio_stream_ind_msg_v01,
+					   interrupter_num),
+	},
+	{
 		.data_type      = QMI_EOTI,
 		.is_array       = NO_ARRAY,
 		.is_array       = QMI_COMMON_TLV_TYPE,
diff --git a/sound/usb/usb_audio_qmi_v01.h b/sound/usb/usb_audio_qmi_v01.h
index 18becc0..83a966c 100644
--- a/sound/usb/usb_audio_qmi_v01.h
+++ b/sound/usb/usb_audio_qmi_v01.h
@@ -13,7 +13,7 @@
 #ifndef USB_QMI_V01_H
 #define USB_QMI_V01_H
 
-#define UAUDIO_STREAM_SERVICE_ID_V01 0x41C
+#define UAUDIO_STREAM_SERVICE_ID_V01 0x41D
 #define UAUDIO_STREAM_SERVICE_VERS_V01 0x01
 
 #define QMI_UAUDIO_STREAM_RESP_V01 0x0001
@@ -58,46 +58,93 @@
 	uint8_t iInterface;
 };
 
+enum usb_audio_stream_status_enum_v01 {
+	USB_AUDIO_STREAM_STATUS_ENUM_MIN_VAL_V01 = INT_MIN,
+	USB_AUDIO_STREAM_REQ_SUCCESS_V01 = 0,
+	USB_AUDIO_STREAM_REQ_FAILURE_V01 = 1,
+	USB_AUDIO_STREAM_REQ_FAILURE_NOT_FOUND_V01 = 2,
+	USB_AUDIO_STREAM_REQ_FAILURE_INVALID_PARAM_V01 = 3,
+	USB_AUDIO_STREAM_REQ_FAILURE_MEMALLOC_V01 = 4,
+	USB_AUDIO_STREAM_STATUS_ENUM_MAX_VAL_V01 = INT_MAX,
+};
+
+enum usb_audio_device_indication_enum_v01 {
+	USB_AUDIO_DEVICE_INDICATION_ENUM_MIN_VAL_V01 = INT_MIN,
+	USB_AUDIO_DEV_CONNECT_V01 = 0,
+	USB_AUDIO_DEV_DISCONNECT_V01 = 1,
+	USB_AUDIO_DEV_SUSPEND_V01 = 2,
+	USB_AUDIO_DEV_RESUME_V01 = 3,
+	USB_AUDIO_DEVICE_INDICATION_ENUM_MAX_VAL_V01 = INT_MAX,
+};
+
 struct qmi_uaudio_stream_req_msg_v01 {
-	uint32_t priv_data;
 	uint8_t enable;
 	uint32_t usb_token;
+	uint8_t audio_format_valid;
 	uint32_t audio_format;
+	uint8_t number_of_ch_valid;
 	uint32_t number_of_ch;
+	uint8_t bit_rate_valid;
 	uint32_t bit_rate;
+	uint8_t xfer_buff_size_valid;
 	uint32_t xfer_buff_size;
 };
-#define QMI_UAUDIO_STREAM_REQ_MSG_V01_MAX_MSG_LEN 46
+#define QMI_UAUDIO_STREAM_REQ_MSG_V01_MAX_MSG_LEN 39
 extern struct elem_info qmi_uaudio_stream_req_msg_v01_ei[];
 
 struct qmi_uaudio_stream_resp_msg_v01 {
-	uint32_t priv_data;
-	uint32_t status;
+	struct qmi_response_type_v01 resp;
+	uint8_t status_valid;
+	enum usb_audio_stream_status_enum_v01 status;
+	uint8_t internal_status_valid;
+	uint32_t internal_status;
+	uint8_t slot_id_valid;
 	uint32_t slot_id;
-	uint8_t bSubslotSize;
+	uint8_t usb_token_valid;
+	uint32_t usb_token;
+	uint8_t std_as_opr_intf_desc_valid;
 	struct usb_interface_descriptor_v01 std_as_opr_intf_desc;
+	uint8_t std_as_data_ep_desc_valid;
 	struct usb_endpoint_descriptor_v01 std_as_data_ep_desc;
+	uint8_t std_as_sync_ep_desc_valid;
 	struct usb_endpoint_descriptor_v01 std_as_sync_ep_desc;
-	uint8_t bDelay;
-	uint16_t bcdADC;
+	uint8_t usb_audio_spec_revision_valid;
+	uint16_t usb_audio_spec_revision;
+	uint8_t data_path_delay_valid;
+	uint8_t data_path_delay;
+	uint8_t usb_audio_subslot_size_valid;
+	uint8_t usb_audio_subslot_size;
+	uint8_t xhci_mem_info_valid;
 	struct apps_mem_info_v01 xhci_mem_info;
+	uint8_t interrupter_num_valid;
 	uint8_t interrupter_num;
 };
-#define QMI_UAUDIO_STREAM_RESP_MSG_V01_MAX_MSG_LEN 177
+#define QMI_UAUDIO_STREAM_RESP_MSG_V01_MAX_MSG_LEN 191
 extern struct elem_info qmi_uaudio_stream_resp_msg_v01_ei[];
 
 struct qmi_uaudio_stream_ind_msg_v01 {
-	uint32_t usb_token;
-	uint32_t priv_data;
-	uint32_t status;
+	enum usb_audio_device_indication_enum_v01 dev_event;
 	uint32_t slot_id;
-	uint8_t bSubslotSize;
+	uint8_t usb_token_valid;
+	uint32_t usb_token;
+	uint8_t std_as_opr_intf_desc_valid;
 	struct usb_interface_descriptor_v01 std_as_opr_intf_desc;
+	uint8_t std_as_data_ep_desc_valid;
 	struct usb_endpoint_descriptor_v01 std_as_data_ep_desc;
+	uint8_t std_as_sync_ep_desc_valid;
 	struct usb_endpoint_descriptor_v01 std_as_sync_ep_desc;
+	uint8_t usb_audio_spec_revision_valid;
+	uint16_t usb_audio_spec_revision;
+	uint8_t data_path_delay_valid;
+	uint8_t data_path_delay;
+	uint8_t usb_audio_subslot_size_valid;
+	uint8_t usb_audio_subslot_size;
+	uint8_t xhci_mem_info_valid;
 	struct apps_mem_info_v01 xhci_mem_info;
+	uint8_t interrupter_num_valid;
+	uint8_t interrupter_num;
 };
-#define QMI_UAUDIO_STREAM_IND_MSG_V01_MAX_MSG_LEN 171
+#define QMI_UAUDIO_STREAM_IND_MSG_V01_MAX_MSG_LEN 177
 extern struct elem_info qmi_uaudio_stream_ind_msg_v01_ei[];
 
 #endif