Only enable IT frame on JPEG capture, this saves some CPU
interruptions and processing on all the other cases.
Signed-off-by: Hugues Fruchet <hugues.fruchet@st.com>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
        }
 
        /* Enable interruptions */
-       reg_set(dcmi->regs, DCMI_IER, IT_FRAME | IT_OVR | IT_ERR);
+       if (dcmi->sd_format->fourcc == V4L2_PIX_FMT_JPEG)
+               reg_set(dcmi->regs, DCMI_IER, IT_FRAME | IT_OVR | IT_ERR);
+       else
+               reg_set(dcmi->regs, DCMI_IER, IT_OVR | IT_ERR);
 
        return 0;