Linux USB
 help / color / mirror / Atom feed
* [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances
@ 2026-12-03 19:32 Vineet Thakran
  2026-12-03 19:32 ` [PATCH 1/4] usb: gadget: f_uac2: use per-instance feature unit IDs in control requests Vineet Thakran
                   ` (4 more replies)
  0 siblings, 5 replies; 8+ messages in thread
From: Vineet Thakran @ 2026-12-03 19:32 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neill Kapron
  Cc: Ruslan Bilovol, Pavel Hofman, linux-usb, Vineet Thakran

f_uac1 and f_uac2 keep the dynamically allocated feature unit (and, in
f_uac1, AC header) descriptors in file-scope pointers shared by all
instances. With more than one instance this leaks descriptors on every
bind (reported by syzbot for f_uac2), and once one instance unbinds, a
feature unit control request to any other bound instance dereferences
a NULL pointer.

Patches 1 and 3 make the control request handlers use the unit IDs
already stored per instance. Patches 2 and 4 then free the descriptors
at the end of bind, as usb_assign_descriptors() has copied them by then.

Testing (next-20261127, arm64 QEMU, usbip-vudc as UDC, kmemleak on):
 - syzbot's C reproducer: reports the build_fu_desc leak before the
   series; runs for 180 s without any leak after it.
 - Two uac2 and two uac1 instances in one config, bound/unbound for
   3 and 8 cycles: kmemleak reports leaked FU descriptors before the
   series (10 objects after 3 cycles, 27 after 8) and none after.
   Counting allocations and frees with temporary instrumentation also
   confirms the uac1 AC header leak, which kmemleak does not report:
   3 of 6 freed before, 6 of 6 after.
 - Two gadgets on two vudc instances, unbinding the first and attaching
   the second to vhci-hcd: both drivers oops on the first feature unit
   control request before the series. After it, snd-usb-audio enumerates
   the device and creates all volume/mute controls.

Both drivers still keep their other descriptors in static variables;
this series only addresses the dynamically allocated ones.

Vineet Thakran (4):
  usb: gadget: f_uac2: use per-instance feature unit IDs in control
    requests
  usb: gadget: f_uac2: fix feature unit descriptor leak
  usb: gadget: f_uac1: use per-instance feature unit IDs in control
    requests
  usb: gadget: f_uac1: fix feature unit and AC header descriptor leak

 drivers/usb/gadget/function/f_uac1.c | 83 +++++++++++++---------------
 drivers/usb/gadget/function/f_uac2.c | 83 ++++++++++++++--------------
 2 files changed, 78 insertions(+), 88 deletions(-)


base-commit: e5aad2bdbbee783611d32599f89cea3f12f9593d
-- 
2.43.0

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH 1/4] usb: gadget: f_uac2: use per-instance feature unit IDs in control requests
  2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
@ 2026-12-03 19:32 ` Vineet Thakran
  2026-12-03 19:32 ` [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak Vineet Thakran
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 8+ messages in thread
From: Vineet Thakran @ 2026-12-03 19:32 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neill Kapron
  Cc: Ruslan Bilovol, Pavel Hofman, linux-usb, Vineet Thakran, stable

The class-specific control request handlers look up the feature unit
IDs through the file-scope in_feature_unit_desc/out_feature_unit_desc
pointers. These pointers are shared by every f_uac2 instance, but each
instance allocates its own descriptors in afunc_bind() and
afunc_unbind() frees them and sets the pointers to NULL.

So once one instance unbinds, every other instance that is still bound
dereferences a NULL pointer on the next feature unit control request
from the host. With two gadgets, each with a uac2 function on its own
UDC, unbinding the first gadget and connecting the second to a host
gives:

  Unable to handle kernel NULL pointer dereference at virtual address 0000000000000003
  pc : afunc_setup+0x2f8/0x568

afunc_bind() already stores each unit ID in agdev->params.p_fu.id and
agdev->params.c_fu.id, which live as long as the instance. Make the
USB_IN_FU_ID()/USB_OUT_FU_ID() macros read those per-instance values
instead, and fill them directly from the descriptors in afunc_bind().

This also means nothing uses the feature unit descriptors after bind,
which the following patch relies on.

Fixes: eaf6cbe09920 ("usb: gadget: f_uac2: add volume and mute support")
Cc: stable@vger.kernel.org
Signed-off-by: Vineet Thakran <vineet789thakran@gmail.com>
---
 drivers/usb/gadget/function/f_uac2.c | 30 ++++++++++++++--------------
 1 file changed, 15 insertions(+), 15 deletions(-)

diff --git a/drivers/usb/gadget/function/f_uac2.c b/drivers/usb/gadget/function/f_uac2.c
index a5f3d4d6c34b..dca8c6d7640c 100644
--- a/drivers/usb/gadget/function/f_uac2.c
+++ b/drivers/usb/gadget/function/f_uac2.c
@@ -31,8 +31,8 @@
  */
 #define USB_OUT_CLK_ID	(out_clk_src_desc.bClockID)
 #define USB_IN_CLK_ID	(in_clk_src_desc.bClockID)
-#define USB_OUT_FU_ID	(out_feature_unit_desc->bUnitID)
-#define USB_IN_FU_ID	(in_feature_unit_desc->bUnitID)
+#define USB_OUT_FU_ID(_agdev)	((_agdev)->params.c_fu.id)
+#define USB_IN_FU_ID(_agdev)	((_agdev)->params.p_fu.id)
 
 #define CONTROL_ABSENT	0
 #define CONTROL_RDONLY	1
@@ -1340,7 +1340,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 			sizeof(agdev->params.p_srates));
 	agdev->params.p_ssize = uac2_opts->p_ssize;
 	if (FUIN_EN(uac2_opts)) {
-		agdev->params.p_fu.id = USB_IN_FU_ID;
+		agdev->params.p_fu.id = in_feature_unit_desc->bUnitID;
 		agdev->params.p_fu.mute_present = uac2_opts->p_mute_present;
 		agdev->params.p_fu.volume_present = uac2_opts->p_volume_present;
 		agdev->params.p_fu.volume_min = uac2_opts->p_volume_min;
@@ -1352,7 +1352,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 			sizeof(agdev->params.c_srates));
 	agdev->params.c_ssize = uac2_opts->c_ssize;
 	if (FUOUT_EN(uac2_opts)) {
-		agdev->params.c_fu.id = USB_OUT_FU_ID;
+		agdev->params.c_fu.id = out_feature_unit_desc->bUnitID;
 		agdev->params.c_fu.mute_present = uac2_opts->c_mute_present;
 		agdev->params.c_fu.volume_present = uac2_opts->c_volume_present;
 		agdev->params.c_fu.volume_min = uac2_opts->c_volume_min;
@@ -1586,11 +1586,11 @@ in_rq_cur(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 				"%s:%d control_selector=%d TODO!\n",
 				__func__, __LINE__, control_selector);
 		}
-	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(agdev)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_MUTE) {
@@ -1675,11 +1675,11 @@ in_rq_range(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 				"%s:%d control_selector=%d TODO!\n",
 				__func__, __LINE__, control_selector);
 		}
-	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(agdev)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_VOLUME) {
@@ -1765,11 +1765,11 @@ out_rq_cur_complete(struct usb_ep *ep, struct usb_request *req)
 		return;
 	}
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-		(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev))) ||
+		(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(agdev)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_MUTE) {
@@ -1819,8 +1819,8 @@ out_rq_cur(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 			req->complete = uac2_cs_control_sam_freq;
 			return w_length;
 		}
-	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	} else if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(agdev))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(agdev)))) {
 		memcpy(&uac2->setup_cr, cr, sizeof(*cr));
 		req->context = agdev;
 		req->complete = out_rq_cur_complete;
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak
  2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
  2026-12-03 19:32 ` [PATCH 1/4] usb: gadget: f_uac2: use per-instance feature unit IDs in control requests Vineet Thakran
@ 2026-12-03 19:32 ` Vineet Thakran
  2026-12-03 19:54   ` sashiko-bot
  2026-12-03 19:32 ` [PATCH 3/4] usb: gadget: f_uac1: use per-instance feature unit IDs in control requests Vineet Thakran
                   ` (2 subsequent siblings)
  4 siblings, 1 reply; 8+ messages in thread
From: Vineet Thakran @ 2026-12-03 19:32 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neill Kapron
  Cc: Ruslan Bilovol, Pavel Hofman, linux-usb, Vineet Thakran,
	syzbot+da5ce3f4a00c8cbe0d4e, stable

afunc_bind() allocates the feature unit descriptors and stores them in
the file-scope in_feature_unit_desc/out_feature_unit_desc pointers,
which are freed only in afunc_unbind(). When a configuration contains
more than one f_uac2 instance, each bind overwrites the pointers left
by the previous one, and those descriptors are leaked:

  unreferenced object 0xffff888111d43640 (size 32):
    build_fu_desc+0x3f/0x70 drivers/usb/gadget/function/f_uac2.c:773
    afunc_bind+0x1414/0x16a0 drivers/usb/gadget/function/f_uac2.c:1062
    usb_add_function+0xca/0x270 drivers/usb/gadget/composite.c:333
    configfs_composite_bind+0x667/0x9b0 drivers/usb/gadget/configfs.c:1803

usb_assign_descriptors() copies the descriptors into the function, and
since the previous patch nothing uses them after afunc_bind(). Free them
on every exit path of afunc_bind(), including success, and drop the now
redundant kfree() calls from afunc_unbind().

The set_ep_max_packet_size_bint() error paths also returned without
freeing the descriptors. They cannot trigger today, as that function
only fails for an unknown speed, but route them through the same
cleanup so that every exit path releases the descriptors.

Reported-by: syzbot+da5ce3f4a00c8cbe0d4e@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=da5ce3f4a00c8cbe0d4e
Fixes: eaf6cbe09920 ("usb: gadget: f_uac2: add volume and mute support")
Cc: stable@vger.kernel.org
Signed-off-by: Vineet Thakran <vineet789thakran@gmail.com>
---
 drivers/usb/gadget/function/f_uac2.c | 53 +++++++++++++---------------
 1 file changed, 25 insertions(+), 28 deletions(-)

diff --git a/drivers/usb/gadget/function/f_uac2.c b/drivers/usb/gadget/function/f_uac2.c
index dca8c6d7640c..6851832ca7d0 100644
--- a/drivers/usb/gadget/function/f_uac2.c
+++ b/drivers/usb/gadget/function/f_uac2.c
@@ -1095,7 +1095,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		in_feature_unit_desc = build_fu_desc(p_channels);
 		if (!in_feature_unit_desc) {
 			ret = -ENOMEM;
-			goto err_free_fu;
+			goto free_fu;
 		}
 	}
 
@@ -1163,7 +1163,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 	ret = usb_interface_id(cfg, fn);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		goto err_free_fu;
+		goto free_fu;
 	}
 	iad_desc.bFirstInterface = ret;
 
@@ -1175,7 +1175,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		ret = usb_interface_id(cfg, fn);
 		if (ret < 0) {
 			dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-			goto err_free_fu;
+			goto free_fu;
 		}
 		std_as_out_if0_desc.bInterfaceNumber = ret;
 		std_as_out_if1_desc.bInterfaceNumber = ret;
@@ -1205,7 +1205,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		ret = usb_interface_id(cfg, fn);
 		if (ret < 0) {
 			dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-			goto err_free_fu;
+			goto free_fu;
 		}
 		std_as_in_if0_desc.bInterfaceNumber = ret;
 		std_as_in_if1_desc.bInterfaceNumber = ret;
@@ -1219,7 +1219,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		if (!uac2->int_ep) {
 			dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
 			ret = -ENODEV;
-			goto err_free_fu;
+			goto free_fu;
 		}
 
 		std_ac_if_desc.bNumEndpoints = 1;
@@ -1235,42 +1235,42 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 					USB_SPEED_FULL, true);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	ret = set_ep_max_packet_size_bint(dev, uac2_opts, &fs_epout_desc,
 					USB_SPEED_FULL, false);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	ret = set_ep_max_packet_size_bint(dev, uac2_opts, &hs_epin_desc,
 					USB_SPEED_HIGH, true);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	ret = set_ep_max_packet_size_bint(dev, uac2_opts, &hs_epout_desc,
 					USB_SPEED_HIGH, false);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	ret = set_ep_max_packet_size_bint(dev, uac2_opts, &ss_epin_desc,
 					USB_SPEED_SUPER, true);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	ret = set_ep_max_packet_size_bint(dev, uac2_opts, &ss_epout_desc,
 					USB_SPEED_SUPER, false);
 	if (ret < 0) {
 		dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
-		return ret;
+		goto free_fu;
 	}
 
 	if (EPOUT_EN(uac2_opts)) {
@@ -1278,7 +1278,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		if (!agdev->out_ep) {
 			dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
 			ret = -ENODEV;
-			goto err_free_fu;
+			goto free_fu;
 		}
 		if (EPOUT_FBACK_IN_EN(uac2_opts)) {
 			agdev->in_ep_fback = usb_ep_autoconfig(gadget,
@@ -1287,7 +1287,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 				dev_err(dev, "%s:%d Error!\n",
 					__func__, __LINE__);
 				ret = -ENODEV;
-				goto err_free_fu;
+				goto free_fu;
 			}
 		}
 	}
@@ -1297,7 +1297,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 		if (!agdev->in_ep) {
 			dev_err(dev, "%s:%d Error!\n", __func__, __LINE__);
 			ret = -ENODEV;
-			goto err_free_fu;
+			goto free_fu;
 		}
 	}
 
@@ -1331,7 +1331,7 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
 	ret = usb_assign_descriptors(fn, fs_audio_desc, hs_audio_desc, ss_audio_desc,
 				     ss_audio_desc);
 	if (ret)
-		goto err_free_fu;
+		goto free_fu;
 
 	agdev->gadget = gadget;
 
@@ -1366,15 +1366,17 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
     agdev->notify = afunc_notify;
 
 	ret = g_audio_setup(agdev, "UAC2 PCM", "UAC2_Gadget");
-	if (ret)
-		goto err_free_descs;
-
-	return 0;
+	if (ret) {
+		usb_free_all_descriptors(fn);
+		agdev->gadget = NULL;
+	}
 
-err_free_descs:
-	usb_free_all_descriptors(fn);
-	agdev->gadget = NULL;
-err_free_fu:
+free_fu:
+	/*
+	 * The feature unit descriptors are shared by all instances and only
+	 * needed until usb_assign_descriptors() has copied them, so release
+	 * them on every exit path.
+	 */
 	kfree(out_feature_unit_desc);
 	out_feature_unit_desc = NULL;
 	kfree(in_feature_unit_desc);
@@ -2305,11 +2307,6 @@ static void afunc_unbind(struct usb_configuration *c, struct usb_function *f)
 	usb_free_all_descriptors(f);
 
 	agdev->gadget = NULL;
-
-	kfree(out_feature_unit_desc);
-	out_feature_unit_desc = NULL;
-	kfree(in_feature_unit_desc);
-	in_feature_unit_desc = NULL;
 }
 
 static struct usb_function *afunc_alloc(struct usb_function_instance *fi)
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3/4] usb: gadget: f_uac1: use per-instance feature unit IDs in control requests
  2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
  2026-12-03 19:32 ` [PATCH 1/4] usb: gadget: f_uac2: use per-instance feature unit IDs in control requests Vineet Thakran
  2026-12-03 19:32 ` [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak Vineet Thakran
@ 2026-12-03 19:32 ` Vineet Thakran
  2026-12-03 19:32 ` [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak Vineet Thakran
  2026-12-03 19:56 ` [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances sashiko-bot
  4 siblings, 0 replies; 8+ messages in thread
From: Vineet Thakran @ 2026-12-03 19:32 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neill Kapron
  Cc: Ruslan Bilovol, Pavel Hofman, linux-usb, Vineet Thakran, stable

The class-specific control request handlers look up the feature unit
IDs through the file-scope in_feature_unit_desc/out_feature_unit_desc
pointers. These pointers are shared by every f_uac1 instance, but each
instance allocates its own descriptors in f_audio_bind() and
f_audio_unbind() frees them and sets the pointers to NULL.

So once one instance unbinds, every other instance that is still bound
dereferences a NULL pointer on the next feature unit control request
from the host. With two gadgets, each with a uac1 function on its own
UDC, unbinding the first gadget and connecting the second to a host
gives:

  Unable to handle kernel NULL pointer dereference at virtual address 0000000000000003
  pc : f_audio_setup+0x364/0x64c

f_audio_bind() already stores each unit ID in audio->params.p_fu.id and
audio->params.c_fu.id, which live as long as the instance. Make the
USB_IN_FU_ID()/USB_OUT_FU_ID() macros read those per-instance values
instead, and fill them directly from the descriptors in f_audio_bind().

This also means nothing uses the feature unit descriptors after bind,
which the following patch relies on.

Fixes: 0356e6283c71 ("usb: gadget: f_uac1: add volume and mute support")
Cc: stable@vger.kernel.org
Signed-off-by: Vineet Thakran <vineet789thakran@gmail.com>
---
 drivers/usb/gadget/function/f_uac1.c | 42 ++++++++++++++--------------
 1 file changed, 21 insertions(+), 21 deletions(-)

diff --git a/drivers/usb/gadget/function/f_uac1.c b/drivers/usb/gadget/function/f_uac1.c
index 7539817cd407..6a5c00d3a8e6 100644
--- a/drivers/usb/gadget/function/f_uac1.c
+++ b/drivers/usb/gadget/function/f_uac1.c
@@ -23,8 +23,8 @@
 /* UAC1 spec: 3.7.2.3 Audio Channel Cluster Format */
 #define UAC1_CHANNEL_MASK 0x0FFF
 
-#define USB_OUT_FU_ID	(out_feature_unit_desc->bUnitID)
-#define USB_IN_FU_ID	(in_feature_unit_desc->bUnitID)
+#define USB_OUT_FU_ID(_audio)	((_audio)->params.c_fu.id)
+#define USB_IN_FU_ID(_audio)	((_audio)->params.p_fu.id)
 
 #define EPIN_EN(_opts) ((_opts)->p_chmask != 0)
 #define EPOUT_EN(_opts) ((_opts)->c_chmask != 0)
@@ -496,11 +496,11 @@ in_rq_cur(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 	u8 control_selector = w_value >> 8;
 	int value = -EOPNOTSUPP;
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_MUTE) {
@@ -547,11 +547,11 @@ in_rq_min(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 	u8 control_selector = w_value >> 8;
 	int value = -EOPNOTSUPP;
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_VOLUME) {
@@ -594,11 +594,11 @@ in_rq_max(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 	u8 control_selector = w_value >> 8;
 	int value = -EOPNOTSUPP;
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_VOLUME) {
@@ -641,11 +641,11 @@ in_rq_res(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 	u8 control_selector = w_value >> 8;
 	int value = -EOPNOTSUPP;
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_VOLUME) {
@@ -693,11 +693,11 @@ out_rq_cur_complete(struct usb_ep *ep, struct usb_request *req)
 		return;
 	}
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		unsigned int is_playback = 0;
 
-		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID))
+		if (FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio)))
 			is_playback = 1;
 
 		if (control_selector == UAC_FU_MUTE) {
@@ -742,8 +742,8 @@ out_rq_cur(struct usb_function *fn, const struct usb_ctrlrequest *cr)
 	u8 entity_id = (w_index >> 8) & 0xff;
 	u8 control_selector = w_value >> 8;
 
-	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID)) ||
-			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID))) {
+	if ((FUIN_EN(opts) && (entity_id == USB_IN_FU_ID(audio))) ||
+			(FUOUT_EN(opts) && (entity_id == USB_OUT_FU_ID(audio)))) {
 		memcpy(&uac1->setup_cr, cr, sizeof(*cr));
 		req->context = audio;
 		req->complete = out_rq_cur_complete;
@@ -1452,7 +1452,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 			sizeof(audio->params.c_srates));
 	audio->params.c_ssize = audio_opts->c_ssize;
 	if (FUIN_EN(audio_opts)) {
-		audio->params.p_fu.id = USB_IN_FU_ID;
+		audio->params.p_fu.id = in_feature_unit_desc->bUnitID;
 		audio->params.p_fu.mute_present = audio_opts->p_mute_present;
 		audio->params.p_fu.volume_present =
 				audio_opts->p_volume_present;
@@ -1465,7 +1465,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 			sizeof(audio->params.p_srates));
 	audio->params.p_ssize = audio_opts->p_ssize;
 	if (FUOUT_EN(audio_opts)) {
-		audio->params.c_fu.id = USB_OUT_FU_ID;
+		audio->params.c_fu.id = out_feature_unit_desc->bUnitID;
 		audio->params.c_fu.mute_present = audio_opts->c_mute_present;
 		audio->params.c_fu.volume_present =
 				audio_opts->c_volume_present;
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak
  2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
                   ` (2 preceding siblings ...)
  2026-12-03 19:32 ` [PATCH 3/4] usb: gadget: f_uac1: use per-instance feature unit IDs in control requests Vineet Thakran
@ 2026-12-03 19:32 ` Vineet Thakran
  2026-12-03 19:52   ` sashiko-bot
  2026-12-03 19:56 ` [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances sashiko-bot
  4 siblings, 1 reply; 8+ messages in thread
From: Vineet Thakran @ 2026-12-03 19:32 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Neill Kapron
  Cc: Ruslan Bilovol, Pavel Hofman, linux-usb, Vineet Thakran, stable

f_audio_bind() allocates the AC header and feature unit descriptors and
stores them in the file-scope ac_header_desc, in_feature_unit_desc and
out_feature_unit_desc pointers, which are freed only in
f_audio_unbind(). When a configuration contains more than one f_uac1
instance, each bind overwrites the pointers left by the previous one,
and those descriptors are leaked. This is the same problem syzbot
reported for f_uac2.

usb_assign_descriptors() copies the descriptors into the function, and
since the previous patch nothing uses them after f_audio_bind(). Free
them on every exit path of f_audio_bind(), including success, and drop
the now redundant kfree() calls from f_audio_unbind().

Fixes: 254cb1e0d78c ("usb: gadget: f_uac1: disable IN/OUT ep if unused")
Fixes: 0356e6283c71 ("usb: gadget: f_uac1: add volume and mute support")
Cc: stable@vger.kernel.org
Signed-off-by: Vineet Thakran <vineet789thakran@gmail.com>
---
 drivers/usb/gadget/function/f_uac1.c | 41 ++++++++++++----------------
 1 file changed, 17 insertions(+), 24 deletions(-)

diff --git a/drivers/usb/gadget/function/f_uac1.c b/drivers/usb/gadget/function/f_uac1.c
index 6a5c00d3a8e6..2c892db84c65 100644
--- a/drivers/usb/gadget/function/f_uac1.c
+++ b/drivers/usb/gadget/function/f_uac1.c
@@ -1277,14 +1277,14 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 		out_feature_unit_desc = build_fu_desc(audio_opts->c_chmask);
 		if (!out_feature_unit_desc) {
 			status = -ENOMEM;
-			goto fail;
+			goto free_ac_header;
 		}
 	}
 	if (FUIN_EN(audio_opts)) {
 		in_feature_unit_desc = build_fu_desc(audio_opts->p_chmask);
 		if (!in_feature_unit_desc) {
 			status = -ENOMEM;
-			goto err_free_fu;
+			goto free_fu;
 		}
 	}
 
@@ -1372,7 +1372,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	/* allocate instance-specific interface IDs, and patch descriptors */
 	status = usb_interface_id(c, f);
 	if (status < 0)
-		goto err_free_fu;
+		goto free_fu;
 	ac_interface_desc.bInterfaceNumber = status;
 	uac1->ac_intf = status;
 	uac1->ac_alt = 0;
@@ -1382,7 +1382,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	if (EPOUT_EN(audio_opts)) {
 		status = usb_interface_id(c, f);
 		if (status < 0)
-			goto err_free_fu;
+			goto free_fu;
 		as_out_interface_alt_0_desc.bInterfaceNumber = status;
 		as_out_interface_alt_1_desc.bInterfaceNumber = status;
 		ac_header_desc->baInterfaceNr[ba_iface_id++] = status;
@@ -1393,7 +1393,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	if (EPIN_EN(audio_opts)) {
 		status = usb_interface_id(c, f);
 		if (status < 0)
-			goto err_free_fu;
+			goto free_fu;
 		as_in_interface_alt_0_desc.bInterfaceNumber = status;
 		as_in_interface_alt_1_desc.bInterfaceNumber = status;
 		ac_header_desc->baInterfaceNr[ba_iface_id++] = status;
@@ -1411,7 +1411,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	if (FUOUT_EN(audio_opts) || FUIN_EN(audio_opts)) {
 		ep = usb_ep_autoconfig(cdev->gadget, &ac_int_ep_desc);
 		if (!ep)
-			goto err_free_fu;
+			goto free_fu;
 		uac1->int_ep = ep;
 		uac1->int_ep->desc = &ac_int_ep_desc;
 
@@ -1422,7 +1422,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	if (EPOUT_EN(audio_opts)) {
 		ep = usb_ep_autoconfig(cdev->gadget, &as_out_ep_desc);
 		if (!ep)
-			goto err_free_fu;
+			goto free_fu;
 		ss_as_out_ep_desc.bEndpointAddress = as_out_ep_desc.bEndpointAddress;
 		audio->out_ep = ep;
 		audio->out_ep->desc = &as_out_ep_desc;
@@ -1431,7 +1431,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	if (EPIN_EN(audio_opts)) {
 		ep = usb_ep_autoconfig(cdev->gadget, &as_in_ep_desc);
 		if (!ep)
-			goto err_free_fu;
+			goto free_fu;
 		ss_as_in_ep_desc.bEndpointAddress = as_in_ep_desc.bEndpointAddress;
 		audio->in_ep = ep;
 		audio->in_ep->desc = &as_in_ep_desc;
@@ -1443,7 +1443,7 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 	status = usb_assign_descriptors(f, f_audio_desc, f_audio_desc, f_audio_ss_desc,
 					f_audio_ss_desc);
 	if (status)
-		goto err_free_fu;
+		goto free_fu;
 
 	audio->out_ep_maxpsize = le16_to_cpu(as_out_ep_desc.wMaxPacketSize);
 	audio->in_ep_maxpsize = le16_to_cpu(as_in_ep_desc.wMaxPacketSize);
@@ -1480,18 +1480,19 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
 
 	status = g_audio_setup(audio, "UAC1_PCM", "UAC1_Gadget");
 	if (status)
-		goto err_card_register;
+		usb_free_all_descriptors(f);
 
-	return 0;
-
-err_card_register:
-	usb_free_all_descriptors(f);
-err_free_fu:
+free_fu:
+	/*
+	 * The feature unit and AC header descriptors are shared by all
+	 * instances and only needed until usb_assign_descriptors() has
+	 * copied them, so release them on every exit path.
+	 */
 	kfree(out_feature_unit_desc);
 	out_feature_unit_desc = NULL;
 	kfree(in_feature_unit_desc);
 	in_feature_unit_desc = NULL;
-fail:
+free_ac_header:
 	kfree(ac_header_desc);
 	ac_header_desc = NULL;
 	return status;
@@ -1819,14 +1820,6 @@ static void f_audio_unbind(struct usb_configuration *c, struct usb_function *f)
 	g_audio_cleanup(audio);
 	usb_free_all_descriptors(f);
 
-	kfree(out_feature_unit_desc);
-	out_feature_unit_desc = NULL;
-	kfree(in_feature_unit_desc);
-	in_feature_unit_desc = NULL;
-
-	kfree(ac_header_desc);
-	ac_header_desc = NULL;
-
 	audio->gadget = NULL;
 }
 
-- 
2.43.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak
  2026-12-03 19:32 ` [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak Vineet Thakran
@ 2026-12-03 19:52   ` sashiko-bot
  0 siblings, 0 replies; 8+ messages in thread
From: sashiko-bot @ 2026-12-03 19:52 UTC (permalink / raw)
  To: Vineet Thakran; +Cc: linux-usb

Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] usb: gadget: f_uac1: concurrent f_audio_bind() UAF and
  double-free on globals
--

commit 20d563ef92940baa4fb226b974c5c6ad509ae61d
Author: Vineet Thakran <vineet789thakran@gmail.com>

usb: gadget: f_uac1: fix feature unit and AC header descriptor leak

This commit frees the file-scope AC header and feature unit descriptors
on every exit path of f_audio_bind(), including normal success, and
removes the kfree() calls from f_audio_unbind().

> diff --git a/drivers/usb/gadget/function/f_uac1.c b/drivers/usb/gadget/function/f_uac1.c
> index 6a5c00d3a8e63..2c892db84c656 100644
> --- a/drivers/usb/gadget/function/f_uac1.c
> +++ b/drivers/usb/gadget/function/f_uac1.c

[ ... ]

> @@ -1480,18 +1480,19 @@ static int f_audio_bind(struct usb_configuration *c, struct usb_function *f)
>  
>  	status = g_audio_setup(audio, "UAC1_PCM", "UAC1_Gadget");
>  	if (status)
> -		goto err_card_register;
> +		usb_free_all_descriptors(f);
>  
> -	return 0;
> -
> -err_card_register:
> -	usb_free_all_descriptors(f);
> -err_free_fu:
> +free_fu:
> +	/*
> +	 * The feature unit and AC header descriptors are shared by all
> +	 * instances and only needed until usb_assign_descriptors() has
> +	 * copied them, so release them on every exit path.
> +	 */
>  	kfree(out_feature_unit_desc);
>  	out_feature_unit_desc = NULL;
>  	kfree(in_feature_unit_desc);
>  	in_feature_unit_desc = NULL;
> -fail:
> +free_ac_header:
>  	kfree(ac_header_desc);
>  	ac_header_desc = NULL;
>  	return status;

[Severity: Medium]
Can freeing ac_header_desc, out_feature_unit_desc, and
in_feature_unit_desc on the normal exit path of f_audio_bind() cause a
use-after-free, NULL pointer dereference, or double free when two gadgets
bind concurrently on separate UDCs?

Multi-UDC binding is not globally serialized: gadget_dev_desc_UDC_store()
only holds the per-gadget gi->lock, and gadget_bind_driver() releases
udc_lock before calling driver->bind().  With f_audio_bind() now freeing
these globals after sleeping in g_audio_setup(), two binds can race:

CPU0                                  CPU1
f_audio_bind()
  ac_header_desc = build_ac_...()
  ...
  g_audio_setup() (sleeps)
                                      f_audio_bind()
                                        ac_header_desc = build_ac_...()
                                        out_feature_unit_desc = ...
  kfree(out_feature_unit_desc)
  out_feature_unit_desc = NULL
  kfree(ac_header_desc)
  ac_header_desc = NULL
                                        setup_descriptor(...)
                                          <-- NULL deref / use-after-free

CPU0 frees and clears the descriptors allocated by CPU1 while CPU1 is
still using them, causing a use-after-free or NULL pointer dereference.
If both CPUs enter free_fu before either writes NULL, both pass the same
pointer to kfree() and trigger a double free.

Making ac_header_desc, out_feature_unit_desc, and in_feature_unit_desc
local variables in f_audio_bind() (passed to setup_descriptor()) removes
their shared lifetime, and a file-scope mutex around descriptor setup
would serialize the remaining shared static descriptors.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261203193217.465889-1-vineet789thakran@gmail.com?part=4

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak
  2026-12-03 19:32 ` [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak Vineet Thakran
@ 2026-12-03 19:54   ` sashiko-bot
  0 siblings, 0 replies; 8+ messages in thread
From: sashiko-bot @ 2026-12-03 19:54 UTC (permalink / raw)
  To: Vineet Thakran; +Cc: linux-usb

Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Medium] usb: gadget: f_uac2: concurrent afunc_bind() race on feature
  unit descriptors
--

commit b460ba36b386cc9343677b189193698795073c6a
Author: Vineet Thakran <vineet789thakran@gmail.com>

usb: gadget: f_uac2: fix feature unit descriptor leak

This commit frees the file-scope in_feature_unit_desc and
out_feature_unit_desc pointers on every exit path of afunc_bind(),
including normal return, and removes the kfree() calls from
afunc_unbind().

> diff --git a/drivers/usb/gadget/function/f_uac2.c b/drivers/usb/gadget/function/f_uac2.c
> index dca8c6d7640c6..6851832ca7d07 100644
> --- a/drivers/usb/gadget/function/f_uac2.c
> +++ b/drivers/usb/gadget/function/f_uac2.c

[ ... ]

> @@ -1366,15 +1366,17 @@ afunc_bind(struct usb_configuration *cfg, struct usb_function *fn)
>      agdev->notify = afunc_notify;
>  
>  	ret = g_audio_setup(agdev, "UAC2 PCM", "UAC2_Gadget");
> -	if (ret)
> -		goto err_free_descs;
> -
> -	return 0;
> +	if (ret) {
> +		usb_free_all_descriptors(fn);
> +		agdev->gadget = NULL;
> +	}
>  
> -err_free_descs:
> -	usb_free_all_descriptors(fn);
> -	agdev->gadget = NULL;
> -err_free_fu:
> +free_fu:
> +	/*
> +	 * The feature unit descriptors are shared by all instances and only
> +	 * needed until usb_assign_descriptors() has copied them, so release
> +	 * them on every exit path.
> +	 */
>  	kfree(out_feature_unit_desc);
>  	out_feature_unit_desc = NULL;
>  	kfree(in_feature_unit_desc);

[Severity: Medium]
Can concurrent afunc_bind() calls race on out_feature_unit_desc and
in_feature_unit_desc now that every exit path frees and clears them?

Two separate configfs gadgets binding to distinct UDCs can run
afunc_bind() concurrently: gadget_dev_desc_UDC_store() only holds the
per-gadget gi->lock, and gadget_bind_driver() drops udc_lock before
invoking driver->bind().

CPU0                                CPU1
afunc_bind()
  out_feature_unit_desc = P1
  usb_assign_descriptors()
  g_audio_setup() (sleeps)
                                    afunc_bind()
                                      out_feature_unit_desc = P2
                                      setup_descriptor()
  free_fu:
    kfree(out_feature_unit_desc)
    out_feature_unit_desc = NULL
                                      usb_assign_descriptors()
                                        <-- use-after-free on P2

Because afunc_bind() sleeps in g_audio_setup() before reaching free_fu,
the race window is wide.  Depending on timing, CPU1 hits a
use-after-free or NULL pointer dereference, both CPUs can double free
P2 at free_fu, and P1 is still leaked when overwritten.

Serializing descriptor setup and usb_assign_descriptors() in
afunc_bind() with a file-scope mutex (as f_midi2_desc_mutex does in
drivers/usb/gadget/function/f_midi2.c) would prevent both the race and
the concurrent leak.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261203193217.465889-1-vineet789thakran@gmail.com?part=2

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances
  2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
                   ` (3 preceding siblings ...)
  2026-12-03 19:32 ` [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak Vineet Thakran
@ 2026-12-03 19:56 ` sashiko-bot
  4 siblings, 0 replies; 8+ messages in thread
From: sashiko-bot @ 2026-12-03 19:56 UTC (permalink / raw)
  To: Vineet Thakran; +Cc: linux-usb

Sashiko has finished reviewing this 4-patch series:

- Patches 1 and 3: no issues found.
- Patch 2 ("usb: gadget: f_uac2: fix feature unit descriptor leak"): 1
  potential issue (1 Medium)
- Patch 4 ("usb: gadget: f_uac1: fix feature unit and AC header..."): 1
  potential issue (1 Medium)

Detailed reviews have been sent as separate replies to patches 2 and 4.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261203193217.465889-1-vineet789thakran@gmail.com

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2026-12-03 19:56 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-12-03 19:32 [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances Vineet Thakran
2026-12-03 19:32 ` [PATCH 1/4] usb: gadget: f_uac2: use per-instance feature unit IDs in control requests Vineet Thakran
2026-12-03 19:32 ` [PATCH 2/4] usb: gadget: f_uac2: fix feature unit descriptor leak Vineet Thakran
2026-12-03 19:54   ` sashiko-bot
2026-12-03 19:32 ` [PATCH 3/4] usb: gadget: f_uac1: use per-instance feature unit IDs in control requests Vineet Thakran
2026-12-03 19:32 ` [PATCH 4/4] usb: gadget: f_uac1: fix feature unit and AC header descriptor leak Vineet Thakran
2026-12-03 19:52   ` sashiko-bot
2026-12-03 19:56 ` [PATCH 0/4] usb: gadget: f_uac1/f_uac2: fix descriptor leaks and NULL deref with multiple instances sashiko-bot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox