diff options
-rw-r--r-- | drivers/media/video/uvc/uvc_ctrl.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/media/video/uvc/uvc_ctrl.c b/drivers/media/video/uvc/uvc_ctrl.c index f3bd66c500b6..af26bbe6f76e 100644 --- a/drivers/media/video/uvc/uvc_ctrl.c +++ b/drivers/media/video/uvc/uvc_ctrl.c | |||
@@ -1351,9 +1351,12 @@ static int uvc_ctrl_commit_entity(struct uvc_device *dev, | |||
1351 | 1351 | ||
1352 | /* Reset the loaded flag for auto-update controls that were | 1352 | /* Reset the loaded flag for auto-update controls that were |
1353 | * marked as loaded in uvc_ctrl_get/uvc_ctrl_set to prevent | 1353 | * marked as loaded in uvc_ctrl_get/uvc_ctrl_set to prevent |
1354 | * uvc_ctrl_get from using the cached value. | 1354 | * uvc_ctrl_get from using the cached value, and for write-only |
1355 | * controls to prevent uvc_ctrl_set from setting bits not | ||
1356 | * explicitly set by the user. | ||
1355 | */ | 1357 | */ |
1356 | if (ctrl->info.flags & UVC_CTRL_FLAG_AUTO_UPDATE) | 1358 | if (ctrl->info.flags & UVC_CTRL_FLAG_AUTO_UPDATE || |
1359 | !(ctrl->info.flags & UVC_CTRL_FLAG_GET_CUR)) | ||
1357 | ctrl->loaded = 0; | 1360 | ctrl->loaded = 0; |
1358 | 1361 | ||
1359 | if (!ctrl->dirty) | 1362 | if (!ctrl->dirty) |