diff --git a/drivers/usbdev/composite.c b/drivers/usbdev/composite.c index 2cc1ba3955..11a9c09795 100644 --- a/drivers/usbdev/composite.c +++ b/drivers/usbdev/composite.c @@ -579,10 +579,18 @@ static int composite_setup(FAR struct usbdevclass_driver_s *driver, case USB_REQ_SETCONFIGURATION: { - if (ctrl->type == 0 && value != priv->config) + if (ctrl->type == 0) { int i; + if (priv->config == value) + { + /* Already configured -- Do nothing */ + + ret = OK; + break; + } + /* Save the configuration and inform the constituent * classes */