]> rtime.felk.cvut.cz Git - lisovros/linux_canprio.git/blobdiff - drivers/media/video/msp3400-driver.c
[media] msp3400: fix mute audio regression
[lisovros/linux_canprio.git] / drivers / media / video / msp3400-driver.c
index fe18a0ab7acb211433db78c43ae26c863d6ee778..b1763ac93ab3d7a2b24c254f44c1648c94a56f2e 100644 (file)
@@ -381,7 +381,12 @@ static int msp_s_ctrl(struct v4l2_ctrl *ctrl)
 
 void msp_update_volume(struct msp_state *state)
 {
-       v4l2_ctrl_s_ctrl(state->volume, v4l2_ctrl_g_ctrl(state->volume));
+       /* Force an update of the volume/mute cluster */
+       v4l2_ctrl_lock(state->volume);
+       state->volume->val = state->volume->cur.val;
+       state->muted->val = state->muted->cur.val;
+       msp_s_ctrl(state->volume);
+       v4l2_ctrl_unlock(state->volume);
 }
 
 /* --- v4l2 ioctls --- */