From: Roel Kluin <roel.kluin@gmail.com>
To: Mauro Carvalho Chehab <mchehab@infradead.org>,
linux-media@vger.kernel.org,
Andrew Morton <akpm@linux-foundation.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH] mxl5005s: bad checks of state->Mode
Date: Wed, 20 Jan 2010 03:20:14 +0100 [thread overview]
Message-ID: <4B56685E.9060909@gmail.com> (raw)
Regardless of the state->Mode in both cases the same value was
written.
If state->Mode wasn't set, it is always 0.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
drivers/media/common/tuners/mxl5005s.c | 7 +++----
1 files changed, 3 insertions(+), 4 deletions(-)
Or were the ones and zeroes in these MXL_ControlWrite in the wrong place?
diff --git a/drivers/media/common/tuners/mxl5005s.c b/drivers/media/common/tuners/mxl5005s.c
index 605e28b..3967412 100644
--- a/drivers/media/common/tuners/mxl5005s.c
+++ b/drivers/media/common/tuners/mxl5005s.c
@@ -1815,9 +1815,8 @@ static u16 MXL_BlockInit(struct dvb_frontend *fe)
/* Charge Pump Control Dig Ana */
status += MXL_ControlWrite(fe, RFSYN_CHP_GAIN, state->Mode ? 5 : 8);
- status += MXL_ControlWrite(fe,
- RFSYN_EN_CHP_HIGAIN, state->Mode ? 1 : 1);
- status += MXL_ControlWrite(fe, EN_CHP_LIN_B, state->Mode ? 0 : 0);
+ status += MXL_ControlWrite(fe, RFSYN_EN_CHP_HIGAIN, 1);
+ status += MXL_ControlWrite(fe, EN_CHP_LIN_B, 0);
/* AGC TOP Control */
if (state->AGC_Mode == 0) /* Dual AGC */ {
@@ -2161,7 +2160,7 @@ static u16 MXL_IFSynthInit(struct dvb_frontend *fe)
}
}
- if (state->Mode || (state->Mode == 0 && state->IF_Mode == 0)) {
+ if (state->Mode || state->IF_Mode == 0) {
if (state->IF_LO == 57000000UL) {
status += MXL_ControlWrite(fe, IF_DIVVAL, 0x10);
status += MXL_ControlWrite(fe, IF_VCO_BIAS, 0x08);
next reply other threads:[~2010-01-20 2:15 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-20 2:20 Roel Kluin [this message]
2010-01-20 3:23 ` [PATCH] mxl5005s: bad checks of state->Mode Devin Heitmueller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4B56685E.9060909@gmail.com \
--to=roel.kluin@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.