The set mode routines assume that state were changed to the
new mode, otherwise, they'll fail.

Signed-off-by: Mauro Carvalho Chehab <mche...@redhat.com>

diff --git a/drivers/media/dvb/frontends/drxk_hard.c 
b/drivers/media/dvb/frontends/drxk_hard.c
index 74e986f..1d29ed2 100644
--- a/drivers/media/dvb/frontends/drxk_hard.c
+++ b/drivers/media/dvb/frontends/drxk_hard.c
@@ -1837,17 +1837,17 @@ static int SetOperationMode(struct drxk_state *state,
                        */
                switch (oMode) {
                case OM_DVBT:
+                       state->m_OperationMode = oMode;
                        status = SetDVBTStandard(state, oMode);
                        if (status < 0)
                                goto error;
-                       state->m_OperationMode = oMode;
                        break;
                case OM_QAM_ITU_A:      /* fallthrough */
                case OM_QAM_ITU_C:
+                       state->m_OperationMode = oMode;
                        status = SetQAMStandard(state, oMode);
                        if (status < 0)
                                goto error;
-                       state->m_OperationMode = oMode;
                        break;
                case OM_QAM_ITU_B:
                default:
-- 
1.7.1


--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to