From patchwork Mon Jan 10 09:36:24 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Oliver Endriss X-Patchwork-Id: 468161 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id p0A9dSH0031297 for ; Mon, 10 Jan 2011 09:39:28 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753315Ab1AJJjZ (ORCPT ); Mon, 10 Jan 2011 04:39:25 -0500 Received: from mailout-de.gmx.net ([213.165.64.22]:54650 "HELO mail.gmx.net" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with SMTP id S1753115Ab1AJJjY (ORCPT ); Mon, 10 Jan 2011 04:39:24 -0500 Received: (qmail invoked by alias); 10 Jan 2011 09:39:22 -0000 Received: from p5B30AF64.dip.t-dialin.net (HELO charon.escape-edv.de) [91.48.175.100] by mail.gmx.net (mp068) with SMTP; 10 Jan 2011 10:39:22 +0100 X-Authenticated: #476490 X-Provags-ID: V01U2FsdGVkX192o/5/sT12E5sXqRm6HlcJQ8FdcXIttAHE2+sCJb SsAGl3CAsQc4Rm Received: from orion.escape-edv.de (192.168.1.10) by charon.escape-edv.de (192.168.1.9) with esmtp ; Mon, 10 Jan 2011 10:40:03 +0100 From: Oliver Endriss To: linux-media@vger.kernel.org Cc: mchehab@redhat.com Subject: [PATCH 16/16] stv090x: 22kHz workaround must also be performed for the 2nd frontend Date: Mon, 10 Jan 2011 10:36:24 +0100 Message-Id: <1294652184-12843-17-git-send-email-o.endriss@gmx.de> X-Mailer: git-send-email 1.6.5.3 In-Reply-To: <1294652184-12843-1-git-send-email-o.endriss@gmx.de> References: <1294652184-12843-1-git-send-email-o.endriss@gmx.de> X-Y-GMX-Trusted: 0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Mon, 10 Jan 2011 09:39:28 +0000 (UTC) diff --git a/drivers/media/dvb/frontends/stv090x.c b/drivers/media/dvb/frontends/stv090x.c index 1675c2a..6c4c6ef 100644 --- a/drivers/media/dvb/frontends/stv090x.c +++ b/drivers/media/dvb/frontends/stv090x.c @@ -4688,10 +4688,6 @@ static int stv090x_setup(struct dvb_frontend *fe) if (stv090x_write_reg(state, STV090x_TSTRES0, 0x00) < 0) goto err; - /* workaround for stuck DiSEqC output */ - if (config->diseqc_envelope_mode) - stv090x_send_diseqc_burst(fe, SEC_MINI_A); - return 0; err: dprintk(FE_ERROR, 1, "I/O error"); @@ -4762,11 +4758,6 @@ struct dvb_frontend *stv090x_attach(const struct stv090x_config *config, state->internal = temp_int->internal; state->internal->num_used++; dprintk(FE_INFO, 1, "Found Internal Structure!"); - dprintk(FE_ERROR, 1, "Attaching %s demodulator(%d) Cut=0x%02x", - state->device == STV0900 ? "STV0900" : "STV0903", - demod, - state->internal->dev_ver); - return &state->frontend; } else { state->internal = kmalloc(sizeof(struct stv090x_internal), GFP_KERNEL); @@ -4777,15 +4768,20 @@ struct dvb_frontend *stv090x_attach(const struct stv090x_config *config, state->internal->i2c_adap = state->i2c; state->internal->i2c_addr = state->config->address; dprintk(FE_INFO, 1, "Create New Internal Structure!"); - } - mutex_init(&state->internal->demod_lock); - mutex_init(&state->internal->tuner_lock); + mutex_init(&state->internal->demod_lock); + mutex_init(&state->internal->tuner_lock); - if (stv090x_setup(&state->frontend) < 0) { - dprintk(FE_ERROR, 1, "Error setting up device"); - goto error; + if (stv090x_setup(&state->frontend) < 0) { + dprintk(FE_ERROR, 1, "Error setting up device"); + goto error; + } } + + /* workaround for stuck DiSEqC output */ + if (config->diseqc_envelope_mode) + stv090x_send_diseqc_burst(&state->frontend, SEC_MINI_A); + dprintk(FE_ERROR, 1, "Attaching %s demodulator(%d) Cut=0x%02x", state->device == STV0900 ? "STV0900" : "STV0903", demod,