提交 e975be28 编写于 作者: F Felipe Balbi

usb: gadget: function: uvc: return correct alt-setting

If our alternate setting has been selected, we must
return that on a subsequent Get Interface request
even if we're not streaming.
Signed-off-by: NFelipe Balbi <balbi@ti.com>
上级 c92bae75
......@@ -279,7 +279,7 @@ uvc_function_get_alt(struct usb_function *f, unsigned interface)
else if (interface != uvc->streaming_intf)
return -EINVAL;
else
return uvc->state == UVC_STATE_STREAMING ? 1 : 0;
return uvc->video.ep->driver_data ? 1 : 0;
}
static int
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册