All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: olivier.grenie@dibcom.fr
Cc: linux-media@vger.kernel.org
Subject: re: [media] dib7090: add the reference board TFE7090E
Date: Tue, 29 Nov 2011 10:21:50 +0300	[thread overview]
Message-ID: <20111129072150.GA12145@elgon.mountain> (raw)

Hello Olivier Grenie,

This is a semi-automatic email about new static checker warnings.

The patch 6724a2f4f7a6: "[media] dib7090: add the reference board 
TFE7090E" from Aug 5, 2011, leads to the following Smatch complaint:

drivers/media/dvb/frontends/dib0090.c +1146 dib0090_pwm_gain_reset()
	 error: we previously assumed 'state->rf_ramp' could be null (see line 1110)

drivers/media/dvb/frontends/dib0090.c
  1109						if (state->config->is_dib7090e) {
  1110							if (state->rf_ramp == NULL)
                                                            ^^^^^^^^^^^^^^
This test is new.

  1111								dib0090_set_rframp_pwm(state, rf_ramp_pwm_cband_7090e_sensitivity);
  1112							else
  1113								dib0090_set_rframp_pwm(state, state->rf_ramp);
  1114						} else
  1115							dib0090_set_rframp_pwm(state, rf_ramp_pwm_cband_7090);
  1116					}
  1117				} else {
  1118					dib0090_set_rframp_pwm(state, rf_ramp_pwm_cband);
  1119					dib0090_set_bbramp_pwm(state, bb_ramp_pwm_normal);
  1120				}
  1121			} else
  1122	#endif
  1123	#ifdef CONFIG_BAND_VHF
  1124			if (state->current_band == BAND_VHF) {
  1125				if (state->identity.in_soc) {
  1126					dib0090_set_bbramp_pwm(state, bb_ramp_pwm_normal_socs);
  1127				} else {
  1128					dib0090_set_rframp_pwm(state, rf_ramp_pwm_vhf);
  1129					dib0090_set_bbramp_pwm(state, bb_ramp_pwm_normal);
  1130				}
  1131			} else
  1132	#endif
  1133			{
  1134				if (state->identity.in_soc) {
  1135					if (state->identity.version == SOC_8090_P1G_11R1 || state->identity.version == SOC_8090_P1G_21R1)
  1136						dib0090_set_rframp_pwm(state, rf_ramp_pwm_uhf_8090);
  1137					else if (state->identity.version == SOC_7090_P1G_11R1 || state->identity.version == SOC_7090_P1G_21R1)
  1138						dib0090_set_rframp_pwm(state, rf_ramp_pwm_uhf_7090);
  1139					dib0090_set_bbramp_pwm(state, bb_ramp_pwm_normal_socs);
  1140				} else {
  1141					dib0090_set_rframp_pwm(state, rf_ramp_pwm_uhf);
  1142					dib0090_set_bbramp_pwm(state, bb_ramp_pwm_normal);
  1143				}
  1144			}
  1145	
  1146			if (state->rf_ramp[0] != 0)
                            ^^^^^^^^^^^^^^^^^
This is the old dereference.

  1147				dib0090_write_reg(state, 0x32, (3 << 11));
  1148			else

regards,
dan carpenter


             reply	other threads:[~2011-11-29  7:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-29  7:21 Dan Carpenter [this message]
2011-12-06 10:13 ` [media] dib7090: add the reference board TFE7090E Olivier Grenie
2011-12-06 11:00   ` Dan Carpenter

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=20111129072150.GA12145@elgon.mountain \
    --to=dan.carpenter@oracle.com \
    --cc=linux-media@vger.kernel.org \
    --cc=olivier.grenie@dibcom.fr \
    /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.