From patchwork Mon Nov 2 22:51:30 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andreas Regel X-Patchwork-Id: 57172 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id nA2MpZWD027571 for ; Mon, 2 Nov 2009 22:51:35 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932495AbZKBWv3 (ORCPT ); Mon, 2 Nov 2009 17:51:29 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S932493AbZKBWv2 (ORCPT ); Mon, 2 Nov 2009 17:51:28 -0500 Received: from mail.gmx.net ([213.165.64.20]:60793 "HELO mail.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S932378AbZKBWv2 (ORCPT ); Mon, 2 Nov 2009 17:51:28 -0500 Received: (qmail invoked by alias); 02 Nov 2009 22:51:31 -0000 Received: from i59F6A205.versanet.de (EHLO [192.168.0.20]) [89.246.162.5] by mail.gmx.net (mp011) with SMTP; 02 Nov 2009 23:51:31 +0100 X-Authenticated: #126152 X-Provags-ID: V01U2FsdGVkX1+4KOB9Lje4AFXunQmUfrygQBBIZJGRiPgT4DJIrA +imyIe7Vip6BS3 Message-ID: <4AEF6272.7050602@gmx.de> Date: Mon, 02 Nov 2009 23:51:30 +0100 From: Andreas Regel User-Agent: Thunderbird 2.0.0.23 (Windows/20090812) MIME-Version: 1.0 To: linux-media@vger.kernel.org Subject: [PATCH 8/9] stv090x: additional check for packet delineator lock in stv090x_read_status X-Y-GMX-Trusted: 0 X-FuHaFi: 0.49 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org diff -r 07782fabbff1 linux/drivers/media/dvb/frontends/stv090x.c --- a/linux/drivers/media/dvb/frontends/stv090x.c Mon Nov 02 23:09:33 2009 +0100 +++ b/linux/drivers/media/dvb/frontends/stv090x.c Mon Nov 02 23:15:41 2009 +0100 @@ -4136,7 +4136,6 @@ return DVBFE_ALGO_SEARCH_ERROR; } -/* FIXME! */ static int stv090x_read_status(struct dvb_frontend *fe, enum fe_status *status) { struct stv090x_state *state = fe->demodulator_priv; @@ -4158,9 +4157,15 @@ dprintk(FE_DEBUG, 1, "Delivery system: DVB-S2"); reg = STV090x_READ_DEMOD(state, DSTATUS); if (STV090x_GETFIELD_Px(reg, LOCK_DEFINITIF_FIELD)) { - reg = STV090x_READ_DEMOD(state, TSSTATUS); - if (STV090x_GETFIELD_Px(reg, TSFIFO_LINEOK_FIELD)) { - *status = FE_HAS_CARRIER | FE_HAS_VITERBI | FE_HAS_SYNC | FE_HAS_LOCK; + reg = STV090x_READ_DEMOD(state, PDELSTATUS1); + if (STV090x_GETFIELD_Px(reg, PKTDELIN_LOCK_FIELD)) { + reg = STV090x_READ_DEMOD(state, TSSTATUS); + if (STV090x_GETFIELD_Px(reg, TSFIFO_LINEOK_FIELD)) { + *status = FE_HAS_CARRIER | + FE_HAS_VITERBI | + FE_HAS_SYNC | + FE_HAS_LOCK; + } } } break;