From patchwork Tue Feb 1 22:40:36 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Igor M. Liplianin" X-Patchwork-Id: 524301 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 p11MfUS3013997 for ; Tue, 1 Feb 2011 22:41:31 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751470Ab1BAWl3 (ORCPT ); Tue, 1 Feb 2011 17:41:29 -0500 Received: from mail-fx0-f46.google.com ([209.85.161.46]:38207 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751221Ab1BAWl3 (ORCPT ); Tue, 1 Feb 2011 17:41:29 -0500 Received: by mail-fx0-f46.google.com with SMTP id 20so7348272fxm.19 for ; Tue, 01 Feb 2011 14:41:28 -0800 (PST) Received: by 10.223.87.1 with SMTP id u1mr525452fal.112.1296600072351; Tue, 01 Feb 2011 14:41:12 -0800 (PST) Received: from useri.localnet ([93.125.74.3]) by mx.google.com with ESMTPS id n26sm8107673fam.13.2011.02.01.14.41.11 (version=SSLv3 cipher=RC4-MD5); Tue, 01 Feb 2011 14:41:11 -0800 (PST) Subject: [PATCH 4/9 v2] ds3000: loading firmware during demod init To: mchehab@infradead.org, linux-media@vger.kernel.org From: "Igor M. Liplianin" Date: Wed, 2 Feb 2011 00:40:36 +0200 MIME-Version: 1.0 Message-Id: <201102020040.36746.liplianin@me.by> 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]); Tue, 01 Feb 2011 22:41:31 +0000 (UTC) diff --git a/drivers/media/dvb/frontends/ds3000.c b/drivers/media/dvb/frontends/ds3000.c index 02ba759..3373890 100644 --- a/drivers/media/dvb/frontends/ds3000.c +++ b/drivers/media/dvb/frontends/ds3000.c @@ -1056,14 +1056,6 @@ static int ds3000_tune(struct dvb_frontend *fe, dprintk("%s() ", __func__); - /* Load the firmware if required */ - ret = ds3000_firmware_ondemand(fe); - if (ret != 0) { - printk(KERN_ERR "%s: Unable initialise the firmware\n", - __func__); - return ret; - } - state->dnxt.delivery = c->modulation; state->dnxt.frequency = c->frequency; state->dnxt.rolloff = 2; /* fixme */ @@ -1353,6 +1345,12 @@ static int ds3000_initfe(struct dvb_frontend *fe) ds3000_tuner_writereg(state, 0x42, 0x73); ds3000_tuner_writereg(state, 0x05, 0x01); ds3000_tuner_writereg(state, 0x62, 0xf5); + /* Load the firmware if required */ + ret = ds3000_firmware_ondemand(fe); + if (ret != 0) { + printk(KERN_ERR "%s: Unable initialize firmware\n", __func__); + return ret; + } return 0; }