summaryrefslogtreecommitdiff
path: root/drivers/usb/gadget/function/u_uac1.h
diff options
context:
space:
mode:
authorYunhao Tian <t123yh.xyz@gmail.com>2022-01-22 14:24:40 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2022-01-26 16:10:40 +0300
commitdfb05b5dc3afd90e564b69b88ff6be6947a0f32f (patch)
tree3ab2bc1b7e728764ebd8c029a7789f1de899a59c /drivers/usb/gadget/function/u_uac1.h
parentd1d11dd1306908bc18b6592bbd21ba7d19a931e5 (diff)
downloadlinux-dfb05b5dc3afd90e564b69b88ff6be6947a0f32f.tar.xz
usb: gadget: f_uac1: allow changing interface name via configfs
This adds "function_name" configfs entry to change string value of the iInterface field. This field will be shown in Windows' audio settings panel, so being able to change it is useful. It will default to "AC Interface" just as before if unchanged. Signed-off-by: Yunhao Tian <t123yh.xyz@gmail.com> Link: https://lore.kernel.org/r/20220122112446.1415547-1-t123yh.xyz@gmail.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/gadget/function/u_uac1.h')
-rw-r--r--drivers/usb/gadget/function/u_uac1.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/gadget/function/u_uac1.h b/drivers/usb/gadget/function/u_uac1.h
index b6cd6171d306..f7a616760e31 100644
--- a/drivers/usb/gadget/function/u_uac1.h
+++ b/drivers/usb/gadget/function/u_uac1.h
@@ -52,6 +52,8 @@ struct f_uac1_opts {
int req_number;
unsigned bound:1;
+ char function_name[32];
+
struct mutex lock;
int refcnt;
};