aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/function/f_ecm.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <[email protected]>2025-05-13 06:19:37 +0000
committerGreg Kroah-Hartman <[email protected]>2025-05-13 06:19:37 +0000
commit991919e969043a4422dfebbcadf600a5d28b94e4 (patch)
tree4776f9f162c665a9735198fafc466d3e49a14253 /drivers/usb/gadget/function/f_ecm.c
parentcomedi: drivers: adl_pci9118.c: Edit file so that checkpatch.pl has 0 typo er... (diff)
parentLinux 6.15-rc6 (diff)
downloadkernel-991919e969043a4422dfebbcadf600a5d28b94e4.tar.gz
kernel-991919e969043a4422dfebbcadf600a5d28b94e4.zip
Merge 6.15-rc6 into char-misc-next
We need the iio/hyperv fixes in here as well. Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'drivers/usb/gadget/function/f_ecm.c')
-rw-r--r--drivers/usb/gadget/function/f_ecm.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/usb/gadget/function/f_ecm.c b/drivers/usb/gadget/function/f_ecm.c
index 80841de845b0..027226325039 100644
--- a/drivers/usb/gadget/function/f_ecm.c
+++ b/drivers/usb/gadget/function/f_ecm.c
@@ -892,6 +892,12 @@ static void ecm_resume(struct usb_function *f)
gether_resume(&ecm->port);
}
+static int ecm_get_status(struct usb_function *f)
+{
+ return (f->func_wakeup_armed ? USB_INTRF_STAT_FUNC_RW : 0) |
+ USB_INTRF_STAT_FUNC_RW_CAP;
+}
+
static void ecm_free(struct usb_function *f)
{
struct f_ecm *ecm;
@@ -960,6 +966,7 @@ static struct usb_function *ecm_alloc(struct usb_function_instance *fi)
ecm->port.func.disable = ecm_disable;
ecm->port.func.free_func = ecm_free;
ecm->port.func.suspend = ecm_suspend;
+ ecm->port.func.get_status = ecm_get_status;
ecm->port.func.resume = ecm_resume;
return &ecm->port.func;