mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-06 10:58:48 +09:00
Revert "usb: gadget: f_uac1: add iad descriptor"
This reverts commit 2ae1313983.
Signed-off-by: Tao Huang <huangtao@rock-chips.com>
Change-Id: I2d38a7647a4523eeabbebc1aa7782b8204b752b4
This commit is contained in:
@@ -48,17 +48,6 @@ static inline struct f_uac1 *func_to_uac1(struct usb_function *f)
|
||||
/* Number of streaming interfaces */
|
||||
#define F_AUDIO_NUM_INTERFACES 2
|
||||
|
||||
static struct usb_interface_assoc_descriptor iad_desc = {
|
||||
.bLength = sizeof(iad_desc),
|
||||
.bDescriptorType = USB_DT_INTERFACE_ASSOCIATION,
|
||||
|
||||
.bFirstInterface = 0,
|
||||
.bInterfaceCount = 3,
|
||||
.bFunctionClass = USB_CLASS_AUDIO,
|
||||
.bFunctionSubClass = USB_SUBCLASS_AUDIOSTREAMING,
|
||||
.bFunctionProtocol = UAC_VERSION_1,
|
||||
};
|
||||
|
||||
/* B.3.1 Standard AC Interface Descriptor */
|
||||
static struct usb_interface_descriptor ac_interface_desc = {
|
||||
.bLength = USB_DT_INTERFACE_SIZE,
|
||||
@@ -258,7 +247,6 @@ static struct uac_iso_endpoint_descriptor as_iso_in_desc = {
|
||||
};
|
||||
|
||||
static struct usb_descriptor_header *f_audio_desc[] = {
|
||||
(struct usb_descriptor_header *)&iad_desc,
|
||||
(struct usb_descriptor_header *)&ac_interface_desc,
|
||||
(struct usb_descriptor_header *)&ac_header_desc,
|
||||
|
||||
@@ -288,7 +276,6 @@ static struct usb_descriptor_header *f_audio_desc[] = {
|
||||
};
|
||||
|
||||
enum {
|
||||
STR_ASSOC,
|
||||
STR_AC_IF,
|
||||
STR_USB_OUT_IT,
|
||||
STR_USB_OUT_IT_CH_NAMES,
|
||||
@@ -303,7 +290,6 @@ enum {
|
||||
};
|
||||
|
||||
static struct usb_string strings_uac1[] = {
|
||||
[STR_ASSOC].s = "Source/Sink",
|
||||
[STR_AC_IF].s = "AC Interface",
|
||||
[STR_USB_OUT_IT].s = "Playback Input terminal",
|
||||
[STR_USB_OUT_IT_CH_NAMES].s = "Playback Channels",
|
||||
@@ -538,8 +524,6 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
|
||||
us = usb_gstrings_attach(cdev, uac1_strings, ARRAY_SIZE(strings_uac1));
|
||||
if (IS_ERR(us))
|
||||
return PTR_ERR(us);
|
||||
|
||||
iad_desc.iFunction = us[STR_ASSOC].id;
|
||||
ac_interface_desc.iInterface = us[STR_AC_IF].id;
|
||||
usb_out_it_desc.iTerminal = us[STR_USB_OUT_IT].id;
|
||||
usb_out_it_desc.iChannelNames = us[STR_USB_OUT_IT_CH_NAMES].id;
|
||||
@@ -576,7 +560,6 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
|
||||
status = usb_interface_id(c, f);
|
||||
if (status < 0)
|
||||
goto fail;
|
||||
iad_desc.bFirstInterface = status;
|
||||
ac_interface_desc.bInterfaceNumber = status;
|
||||
uac1->ac_intf = status;
|
||||
uac1->ac_alt = 0;
|
||||
|
||||
Reference in New Issue
Block a user